How can I circumscribe an ellipse to an image by imagej macro?

I need to circumscribe an ellipse to an image in macro and then section it to 4 (crossing the largest and smallest diameter) and add one of those 4 sections to ROI.
Any idea of how?
I have some sample images to give you a hint of how it might look:
circ 5 circ1 circ2 circ3

What is the geometric shape of your image?

an imagecould help us.

1 Like

@Mathew Just added. Thanks in advance.

Do you need an ellipse? If yes, why?
Why not use “Convex Hull”?

20200125_Inserer une ellipse_1

setAutoThreshold("Huang dark");
//setThreshold(9, 255);
run("Convert to Mask");
run("Fill Holes");
run("Analyze Particles...", "size=1000-Infinity add");
roiManager("Select", 0);
run("Convex Hull");
1 Like

To select the cells:
doWand(84, 297);
doWand(498, 193);
doWand(840, 188);
doWand(90, 620);

To draw the ellipses & quadrants:

What is it you really want to do?


Who is the question for?
If it concerns “convex hull” then:

Convex Hull

Replaces a polygon of freehand selection with its convex hull, which can be thought of as a rubber band wrapped tightly around the points that define the selection.

I’m curious about the method you used to create the ROI selection. How can I select such smooth ROI around the cell boundary.

Many thanks for your reply. I’m aware of convex hull. But I was wondering if @Mathew has the fully automatic selection method.

I found the Edit->Selection->Create selection