Login  Register

Re: Counting pixels above a certain grey value in a stack

Posted by jmutterer on Dec 04, 2007; 3:34pm
URL: http://imagej.273.s1.nabble.com/Counting-pixels-above-a-certain-grey-value-in-a-stack-tp3691747p3691750.html

Hi.
I'm not sure a plugin is necessary in that case. Selecting pixel value
ranges is just exactly what the threshold does. I suggest the following
procedure :
* go to Image/Adjust/Threshold and set the value range you would like to
measure.
* go to Analyze/Set Measurements, and make sure you check the "limit to
threshold" checkbox and the "area" field.
* go to Image/Stacks/Plot Z-axis Profile
You're done.

Jerome


On Dec 4, 2007 2:42 PM, Johannes Schindelin <[hidden email]>
wrote:

> Hi,
>
> On Tue, 4 Dec 2007, Bio7 wrote:
>
> > public class Count_Stack_Pixels implements PlugIn {
>
> If you implement a PlugInFilter (which returns DOES_8G | DOES_16 |
> NO_CHANGES in setup()) you do not need to find out the current image
> or check the image type yourself.
>
> >                               /*We create a dialog!*/
> >                               GenericDialog gd = new
> GenericDialog("Count Pixels");
> >                               gd.addNumericField("Min: ", min, 0);
> >                               gd.addNumericField("Max: ", max, 0);
>
> You could reuse the min/max setting from the threshold.
>
> Ciao,
> Dscho
>