ParticleAnalyser min and max results

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

ParticleAnalyser min and max results

David Rueda
Dear ImageJ users,

I am trying to apply a particle analysis on an osteoclast image. I
encountered some problems with the results which are produced by this
analysis. The problem lie in the min and max values calculated: these
values are equal to zero...
ImageJ also write the following log message:

The display range must first be updated
using Image>Adjust>Brightness/Contrast
or threshold levels defined using
Image>Adjust>Threshold.

Here is the code I am using :

> // open image
> this.imp = IJ.openImage(file.getAbsolutePath());
>
> // image processes
> ContrastEnhancer contrastEnhancer = new ContrastEnhancer();
> contrastEnhancer.stretchHistogram(imp, 0.35);
>
> LutApplier lutApplier = new LutApplier();
> lutApplier.setup("", imp);
> lutApplier.run(imp.getProcessor());
>
> imp.getProcessor().setAutoThreshold(Method.Default, false, ImageProcessor.BLACK_AND_WHITE_LUT);
> imp.getProcessor().autoThreshold();
>
> ResultsTable paResults = new ResultsTable();
> ParticleAnalyzer particleAnalyzer = new ParticleAnalyzer(
>         ParticleAnalyzer.IN_SITU_SHOW | ParticleAnalyzer.SHOW_OUTLINES,
>         Measurements.AREA | Measurements.MEAN | Measurements.MIN_MAX,
>         paResults,
>         0.0,
>         INFINITY
> );
> particleAnalyzer.analyze(imp);
> paResults.saveAs(resFilePath);


Can you see any problem ?

Best Regards,
David