I am trying to estimate the proportion of white pulp and red pulp in the spleen on photographed slides. I am experimenting with a workflow comprising:
- ImageJ correcting for the uneven illumination of the slides (by adding an inverted background image from subtract background), deconvoluting the images into haematoxylin and eosin
- Manually constructing a mask for each slide to remove non-spleen tissue (i.e. liver) and artefact areas
- CellProfiler to threshold the masked haematoxylin image and identify one large object (total spleen)
- Threshold the eosin image (only in the spleen area), then invert it
- Measure the average intensity of the spleen area in the thresholded image to calculate the proportion of white pulp.
I can see how to threshold only the spleen area by using the PerObject setting, however on some slides the staining intensity clearly varies over the surface, and it would be useful to try adaptive thresholding over the spleen surface, but without the remainder of the image (background, liver, etc) biasing the thresholding operation.
From my reading, I believe that if use the newest release of CellProfiler and mask the eosin image to remove the non-spleen areas and leave them black, I can then subtract a small number (0.001) to leave the background negative, and this will then be excluded from the adaptive thresholding operations.
Is this correct? And if so, is it the best way to achieve what I want?