Hi all, so I have this binary image I want to draw a line across and measure lengths in. I have gotten that far (I am able to automate line drawing and measuring those lines). The issue I am having is that I want to EXCLUDE regions greater than a certain length (so if I have an image of 30 black circles in a row on a white background with arbitrary diameters ranging from 15 pixel units to 100 pixel units, but i do not know the distribution of these circles in my images, I want to be able to EXCLUDE any diameter >= 30). The only thing is I want a macro that does what I need because I have 100 images and i need to analyse 100 lines in each image and I don’t want to manually determine which distance is >=30 for each line in each image… So any help how to code this or approach this would be appreciated.
Note: the circles are just examples. I have a tissue histology section in which I want to exclude bronchiole lengths and just include alveolar wall lengths. In the image I have uploaded, I have shown example lines and the regions they intersect. I want to be able to exclude any black region >= 30um (~50 pixels I think…) that intersects with my line and then subtract that length out from the total length of the line (for each line, respectively) in an automated fashion. Please let me know if anyone has any suggestion