Login  Register

Re: Circle with 200um diameter

Posted by Wayne Rasband on Jul 17, 2007; 5:42pm
URL: http://imagej.273.s1.nabble.com/Ratiometric-Analysis-using-Image-J-tp3698844p3698847.html

Here is a macro tool that draws circles. Double click on the tool to
change the circle diameter. Double click on the eye dropper tool to
change the color used to draw the circles. Use the Analyze>Set Scale
command to define the unit and scale. Add the code to
ImageJ/macros/StartupMacros.txt to have the tool added to the tool bar
when ImageJ starts.

-wayne

     var diameter = 200;
     macro "Circle Tool - C00cO11cc" {
         getCursorLoc(x, y, z, flags);
         getPixelSize(unit, w, h);
         d = diameter;
         drawOval(x-d/(w*2), y-d/(h*2), d/w, d/h);
     }
     macro "Circle Tool Options" {
         getPixelSize(unit, w, h);
         diameter = getNumber("Diameter ("+unit+"): ", diameter);
     }


On Jul 17, 2007, at 12:45 PM, B. Prabhakar Pandian wrote:

> Hello,
>          I have multiple images in which I want to create a circle
> with 200µm diameter with a varying specified point as the center of
> the circle. Is there a way  I can do this.
> I am a beginner in ImageJ so any suggestions will help me a lot.
>
> Thanks,
>
> -Prabhakar
>