Create ROI around particle



Hi, I’m trying to create an automated method to count cellular inclusion bodies that are “around” a nuclei, i.e. a particle.

I haven’t figured out a way to do this in ImageJ/FIJI.

Conceptually, I have a stack (image1, image2).
What I’d like to do is use “image1” to define the particle (in this case nuclei) and then build a radius (for example, 200px) ROI around this particle.
I would pass this ROI to “image2” which would then count the particles (inclusion bodies) in the ROI.
There would be multiple ROIs per image, so ideally I would like to get multiple readings of the particles (inclusion bodies) per cell in each image.

I can do most of the macro programming, but I’m stuck on figuring out how best to create the radius ROI. Using something like the watershed analysis (which finds the center) should be useful, but I can’t figure out how to proceed.

Thanks for any tips or help!


Hi @Chris4,

Without seeing a typical example image giving any helpful hint is difficult. But it sounds like this video might give hints on how you achieve this step by step.

If you then still have trouble with it, best post an example image of the two channels (avoiding jpeg).


As an update and for others, here is the working macro that I have created to date. It’s not well commented, but if anyone has questions feel free to post and I’ll explain it more.

name = getTitle(); 

run("Convert to Mask", "method=Yen background=Dark calculate black");
run("Find Maxima...", "noise=100 output=List exclude");
dir =; 
name = File.nameWithoutExtension;

radius = 500;
n = nResults;
for (i=0; i<n; i++){
		x = getResult("X",i);
		y = getResult("Y",i);
		makeOval(x-radius/2,y-radius/2, radius, radius);

//after getting the ROI, this applies the ROI to the 2nd layer
run("Delete Slice");
    setOption("BlackBackground", false);
run("Convert to Mask", "method=Yen background=Dark calculate");

//this actually counts the particles in the second layer    
macro "Count in multiple ROI..." {
  n = roiManager("count");
  for (i=0; i<n; i++) {
      roiManager("select", i);
 run("Analyze Particles...", "size=10-500 circularity=0.10-1.00 display summarize exclude");

 } //Closes the bracket in the "i" portion

 } //Closes the entire macro


Hi @Chris4,

you also might want to have a look at the Speckle Inspector which automates the analysis for you after your thresholding and gives some further output besides the counts.