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


run("8-bit");
setAutoThreshold("Huang dark");
//run("Threshold...");
//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:
run(“Threshold…”);
//setTool(“wand”);
doWand(84, 297);
roiManager(“Add”);
doWand(498, 193);
roiManager(“Add”);
doWand(840, 188);
roiManager(“Add”);
doWand(90, 620);
roiManager(“Add”);

To draw the ellipses & quadrants:
https://imagej.nih.gov/ij/macros/DrawEllipse.txt

What is it you really want to do?
Cheers-
michael.cammer@nyulangone.org

Hi
@WeisongZhao

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.

https://imagej.nih.gov/ij/docs/menus/edit.html

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