Login  Register

Re: subcounting objects

Posted by Stoyan Pavlov on Jun 20, 2009; 10:15pm
URL: http://imagej.273.s1.nabble.com/subcounting-objects-tp3692066p3692067.html

Hi Paolo,
I had similar problem recently. I solved it using the folowing macro. Please
excuse me because I am not really good with the macro language and the macro
is a bit sluggish but it worked for me. You can modify so it is more
appropriate to your needs.Here it is:

// This Macro counts particles inside specific Roi and otputs the number to
TAB separated Log window which after saving can be imported to excel.
        n = roiManager("count");
        for (i=0; i<n; i++)  {
        roiManager("select", i);
         run("Analyze Particles...", "size=2-20 circularity=0.00-1.00
show=Nothing display clear ");
    m=nResults;
        print (i,"    ",":","    ", m) ;

Have a nice day!
Stoyan Pavlov



On Thu, Jun 18, 2009 at 1:39 PM, Paolo Ariano <[hidden email]> wrote:

> Hi all,
>
> i'm trying to count spots in every cells ... so i've two pictures of the
> same field of view:
>
> 1. the first picture shows the whole cells, so treshold and then analyze
> particles and i obtain all the outlines saved and added to the
> roi-manager
>
> 2. then i open the second image containing a lot of little spots inside
> every cells area, now i'd like to count the spots number in every roi
> i've in the roi-manager, how to finish the work ?
>
> thanks a lot
> paolo
> --
> NeuroScience PhD
> Post-doc @ University of Torino
> www.personalweb.unito.it/paolo.ariano
> www.cellular-neurophysiology.unito.it<http://www.personalweb.unito.it/paolo.ariano%0Awww.cellular-neurophysiology.unito.it>
> www.mieleria.it
>



--
Dr. Stoyan P. Pavlov, MD
Departament of Anatomy, Histology and Embryology
Medical University "Prof. Dr. Paraskev Stoyanov", Varna
Prof. Marin Drinov Str.55
9002 Varna
Bulgaria
Tel: +359 (0) 52 - 677 - 050 #2638
e-mail: [hidden email]