How to draw an AOI, dilate it, bring it back and measure color intenisty in the new AOI
I am running IPP 7.0 and I would need some guidance on transferring outlines to AOIs.
I have a fluorophore (green) that is staining in the close proximity of blood vessels (red). I would like to measure the intensity of the green color around the blood vessel and not all the green staining in a given rectangle that I might draw by hand around the vessel.
So I was thinking of the following algorithm:
- Draw AOI of the vessels (by hand or by using the red channel).
- Convert the AOI to an object
- Apply a Dilation morphological filer to the object so that its contour grows with the same number of pixels in all directions.
- Convert back the resulting object to AOI and overlay it on the original image
- Measure the green intensity in the new (dilated) AOI.
- Ideally I would like to substract the original AOI from the dilated one in order to analyze only the ring area around the vessel!
What I did until now was to (1) define first an AOI (freehand or by channel color), (2) convert the AOI to objects, (3) in the Count/Size menu Make Mask, and thus obtain a new image with my AOI as an object. (4) Next on this binary image I applied a dilate morphological filer and the mask grew eccentrically from the original outline with the same number of pixels in al directions. (5) I used the automated threshold (Count/Size) to select the dilated AOI, (6) then Count to generate an object, then (7) I saved the outlines of the object, and lastly, on the original image (8) load outlines. But here the problem is that I cannot make the measurement only inside the outline…
Please, if you have any ideas how this might work best, I would greatly appreciate it!
I am not so good with writing a macro but I can record it very easily in IPP once the workflow is working, so could you please direct me to menu commands?
Thanks so much from now!