ImageJ defining edges

Hello, i’m requesting some help please!
Cant find the way to define the edges, so that imageJ “analyze particles” can analyze each separate particle.
"find edges’ and threshold doesnt seem to help. also tried ‘FeatureJ’ and ‘image edge’ plugins

Hello retgar and welcome,
Do you want only the major components in the image? The more details, the more we can help.

Thank you for your reply
Yes, i want the majority of components but those that are most defined ones and that have black outline, rather than halo ones
Appreciate in advance!

Hey Retgar,

a quick test gave quite promising results:

Convert to 8-bit
Threshold from 0-130, “Apply” to get a binary image
Process => Binary => Fill Holes
Process => Binary => Watershed
Continue with Analyze Particles

Let me know if it helps.

Hello again,
I took a ‘copy’ of the image and went to Process > Binary > Make Binary, then Edit > Invert, followed by Process > Binary > Fill Holes and finally subtracted the ‘Mask’ from Image and obtained the attached.

I hope this helps,

Hello, and thank you for your answer
I tried to do as follows, but inverting gives me fully black image

Hi, thank you for your time!
I have tried your method and results was realy good, but still having a little downsides sometimes.
Like for example, watershed sometimes crop one patricle on two halfs
Also, i tried in a such way using a macro:
subtract background
window/level - auto
Fill holes

But one thing that i noticed, is that thresholding values sometimes may vary, and i guess there is no way to do it automaticaly?

Hey Retgar

the code would look similar to this:

run(“Subtract Background…”, “rolling=30 light sliding disable”);
setAutoThreshold(“Default dark”);
setThreshold(0, 130);
setOption(“BlackBackground”, false);
run(“Convert to Mask”);
run(“Fill Holes”);

if you explicitly state that the threshold is to be applied from x to y you can do this by the setThreshold.
You can also see this thread for further information:

With the overseparation of particles by watershed I will think about a solution.

Hello retgar,
I left it as it is to maintain as much of the natural data as possible because I did not know if you wanted to try to measure cuvature or any other parameters, but if you only want such as area you can just turn the finished image into Process> Binary> Make Binary again and that should do it.
Good work, any more questions just ask.