Analyze Particles changes the results settings

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Analyze Particles changes the results settings

Avital Steinberg
Hi,
I have a problem - when I use Analyze, Particles, it changes the settings
of the result table, so that if I would like to append measurements to the
table, it "forgets" whatever was in the table before the Analyze,
Particles. For example, if I exit before Analyze, Particles, I can see
"This is cell1", but otherwise, it will not appear:

run("Clear Results");
roiManager("Select", 0);
setResult("Cell", 0, "This is cell1");
updateResults();
setThreshold(11581, 36348);
run("Analyze Particles...", "include add");
resetThreshold();
roiManager("Select", 1);
getStatistics(area, mean);
area1 = area;
mean1 = mean;
setResult("Area", 0, area1);

Why would this be?

Thanks,
Avital

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Analyze Particles changes the results settings

Thomas GUILBERT
Hi,
I have the same issue as Avital Steinberg.
More precisely the function "Clear Results" seems to clean the measures
tablebut not nResults var(IJ 1.49v or 1.5b).
Does anyone have an idea ?

Thanks,


Le 02/08/2015 15:56, Avital Steinberg a écrit :

> Hi,
> I have a problem - when I use Analyze, Particles, it changes the settings
> of the result table, so that if I would like to append measurements to the
> table, it "forgets" whatever was in the table before the Analyze,
> Particles. For example, if I exit before Analyze, Particles, I can see
> "This is cell1", but otherwise, it will not appear:
>
> run("Clear Results");
> roiManager("Select", 0);
> setResult("Cell", 0, "This is cell1");
> updateResults();
> setThreshold(11581, 36348);
> run("Analyze Particles...", "include add");
> resetThreshold();
> roiManager("Select", 1);
> getStatistics(area, mean);
> area1 = area;
> mean1 = mean;
> setResult("Area", 0, area1);
>
> Why would this be?
>
> Thanks,
> Avital
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>

--
Thomas GUILBERT, PhD
Plate-Forme Cochin Imagerie,
Institut Cochin - INSERM U1016
Bât. Gustave Roussy 5ème étage
22 rue Méchain, 75014 PARIS
 
tel: 01 40 51 66 55

http://www.cochin.inserm.fr/
[hidden email]

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Analyze Particles changes the results settings

Avital Steinberg
Hi Thomas,
Wayne recommended opening the ROI manager before doing anything else -
somehow, it fixes it. I was programming using the macro language and I had
this issue. Now I have a new, very similar issue when using Javascript:

I can initiate the ROI manager using a boolean argument that specifies if I
want the ROI manager to be displayed. If I try to hide the ROI manager -
bad things happen to my results table. (some of the data disappears from
it) So I am currently displaying the results table all the time.

Does this work around work for you? If anyone knows how to hide the ROI
manager without encountering the problem I'm having - I'll be happy to know.

Thanks,
Avital

On Thu, Sep 10, 2015 at 6:29 PM, Thomas GUILBERT <[hidden email]>
wrote:

> Hi,
> I have the same issue as Avital Steinberg.
> More precisely the function "Clear Results" seems to clean the measures
> tablebut not nResults var(IJ 1.49v or 1.5b).
> Does anyone have an idea ?
>
> Thanks,
>
>
>
> Le 02/08/2015 15:56, Avital Steinberg a écrit :
>
>> Hi,
>> I have a problem - when I use Analyze, Particles, it changes the settings
>> of the result table, so that if I would like to append measurements to the
>> table, it "forgets" whatever was in the table before the Analyze,
>> Particles. For example, if I exit before Analyze, Particles, I can see
>> "This is cell1", but otherwise, it will not appear:
>>
>> run("Clear Results");
>> roiManager("Select", 0);
>> setResult("Cell", 0, "This is cell1");
>> updateResults();
>> setThreshold(11581, 36348);
>> run("Analyze Particles...", "include add");
>> resetThreshold();
>> roiManager("Select", 1);
>> getStatistics(area, mean);
>> area1 = area;
>> mean1 = mean;
>> setResult("Area", 0, area1);
>>
>> Why would this be?
>>
>> Thanks,
>> Avital
>>
>> --
>> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>>
>>
> --
> Thomas GUILBERT, PhD
> Plate-Forme Cochin Imagerie,
> Institut Cochin - INSERM U1016
> Bât. Gustave Roussy 5ème étage
> 22 rue Méchain, 75014 PARIS
>  tel: 01 40 51 66 55
>
> http://www.cochin.inserm.fr/
> [hidden email]
>
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Analyze Particles changes the results settings

Avital Steinberg
In reply to this post by Thomas GUILBERT
Actually, Thomas - thanks for your question. I just made my Javascript
program much faster, because you reminded me of the source of the problem.
(which has something to do with the ROI manager - I forgot about this until
I saw your question)

In the macro language you must show the ROI manager from the beginning of
your script, but in Javascript, it's possible to initiate the ROI manager
like this:

rm = RoiManager(true);

This is in hidden mode. If I use:

rm = getInstance2
<http://rsb.info.nih.gov/ij/developer/api/ij/plugin/frame/RoiManager.html#getInstance2-->
();

Whenever I need to "see" the ROI manager, everything works well.

Good luck,
Avital





On Thu, Sep 10, 2015 at 6:29 PM, Thomas GUILBERT <[hidden email]>
wrote:

> Hi,
> I have the same issue as Avital Steinberg.
> More precisely the function "Clear Results" seems to clean the measures
> tablebut not nResults var(IJ 1.49v or 1.5b).
> Does anyone have an idea ?
>
> Thanks,
>
>
>
> Le 02/08/2015 15:56, Avital Steinberg a écrit :
>
>> Hi,
>> I have a problem - when I use Analyze, Particles, it changes the settings
>> of the result table, so that if I would like to append measurements to the
>> table, it "forgets" whatever was in the table before the Analyze,
>> Particles. For example, if I exit before Analyze, Particles, I can see
>> "This is cell1", but otherwise, it will not appear:
>>
>> run("Clear Results");
>> roiManager("Select", 0);
>> setResult("Cell", 0, "This is cell1");
>> updateResults();
>> setThreshold(11581, 36348);
>> run("Analyze Particles...", "include add");
>> resetThreshold();
>> roiManager("Select", 1);
>> getStatistics(area, mean);
>> area1 = area;
>> mean1 = mean;
>> setResult("Area", 0, area1);
>>
>> Why would this be?
>>
>> Thanks,
>> Avital
>>
>> --
>> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>>
>>
> --
> Thomas GUILBERT, PhD
> Plate-Forme Cochin Imagerie,
> Institut Cochin - INSERM U1016
> Bât. Gustave Roussy 5ème étage
> 22 rue Méchain, 75014 PARIS
>  tel: 01 40 51 66 55
>
> http://www.cochin.inserm.fr/
> [hidden email]
>
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Analyze Particles changes the results settings

Rasband, Wayne (NIH/NIMH) [E]
In reply to this post by Avital Steinberg
On Aug 2, 2015, at 9:56 AM, Avital Steinberg <[hidden email]> wrote:
>
> Hi,
> I have a problem - when I use Analyze, Particles, it changes the settings
> of the result table, so that if I would like to append measurements to the
> table, it "forgets" whatever was in the table before the Analyze,
> Particles.

This bug is fixed in the latest ImageJ daily build (1.50c9). Here is a macro that reproduces the problem:

   run("Clear Results");
   run("Blobs (25K)");
   run("Measure");
   print("nResults (before): "+nResults);
   setAutoThreshold("Default");
   run("Analyze Particles...", "include add");
   print("nResults (after): "+nResults);

With the daily build, it outputs

   nResults (before): 1
   nResults (after): 1

With earlier versions of ImageJ, it outputs

   nResults (before): 1
   nResults (after): 65

-wayne


> For example, if I exit before Analyze, Particles, I can see
> "This is cell1", but otherwise, it will not appear:
>
> run("Clear Results");
> roiManager("Select", 0);
> setResult("Cell", 0, "This is cell1");
> updateResults();
> setThreshold(11581, 36348);
> run("Analyze Particles...", "include add");
> resetThreshold();
> roiManager("Select", 1);
> getStatistics(area, mean);
> area1 = area;
> mean1 = mean;
> setResult("Area", 0, area1);
>
> Why would this be?
>
> Thanks,
> Avital

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

Re: Analyze Particles changes the results settings

Avital Steinberg
Hi Wayne,
I appreciate all your help and I'm happy to contribute to the ImageJ daily
builds,

Avital

On Fri, Sep 11, 2015 at 5:50 AM, Rasband, Wayne (NIH/NIMH) [E] <
[hidden email]> wrote:

> On Aug 2, 2015, at 9:56 AM, Avital Steinberg <[hidden email]>
> wrote:
> >
> > Hi,
> > I have a problem - when I use Analyze, Particles, it changes the settings
> > of the result table, so that if I would like to append measurements to
> the
> > table, it "forgets" whatever was in the table before the Analyze,
> > Particles.
>
> This bug is fixed in the latest ImageJ daily build (1.50c9). Here is a
> macro that reproduces the problem:
>
>    run("Clear Results");
>    run("Blobs (25K)");
>    run("Measure");
>    print("nResults (before): "+nResults);
>    setAutoThreshold("Default");
>    run("Analyze Particles...", "include add");
>    print("nResults (after): "+nResults);
>
> With the daily build, it outputs
>
>    nResults (before): 1
>    nResults (after): 1
>
> With earlier versions of ImageJ, it outputs
>
>    nResults (before): 1
>    nResults (after): 65
>
> -wayne
>
>
> > For example, if I exit before Analyze, Particles, I can see
> > "This is cell1", but otherwise, it will not appear:
> >
> > run("Clear Results");
> > roiManager("Select", 0);
> > setResult("Cell", 0, "This is cell1");
> > updateResults();
> > setThreshold(11581, 36348);
> > run("Analyze Particles...", "include add");
> > resetThreshold();
> > roiManager("Select", 1);
> > getStatistics(area, mean);
> > area1 = area;
> > mean1 = mean;
> > setResult("Area", 0, area1);
> >
> > Why would this be?
> >
> > Thanks,
> > Avital
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
Reply | Threaded
Open this post in threaded view
|

RGB conversion for multi-channel images

LIM Soon Yew John (IMB)
Dear All,

I had noticed that for FIJI (ImageJ 2.0.0-rc-38/1.50b), it ignores the display  mode and active channel when it convert a multi-channels (single time point) to RGB. Please see the example macro below:

run("Fluorescent Cells (400K)");
wait(500);
Stack.setDisplayMode("color");
Stack.setChannel(1);
wait(500);
run("RGB Color");

From the above macro, the final image from current version will always be a RGB composite image instead of RGB stack of different channels unlike previous version of ImageJ.

The current version works as normal for multi-channel images with multiple time-points / slices when I convert them to RGB. Only those with single time-point / slice failed to work as normal.

Best Regards,
John
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html