Results from 3D object counter different from 3D roi manager

Hi,
I noticed that the volume measured and integrated density from the 3D roi manager is different that the one from the 3D object counter.

So for example, if you run the following:

run("3D Manager");

run("Confocal Series (2.2MB)");
run("Duplicate...", "duplicate channels=2");

id=getImageID()
run("Set 3D Measurements", "volume surface integrated_density mean_gray_value bounding_box dots_size=5 font_size=10 show_numbers white_numbers store_results_within_a_table_named_after_the_image_(macro_friendly) redirect_to=none");
run("3D object counter...", "threshold=67 slice=12 min.=10 max.=4000000 objects statistics");
Ext.Manager3D_AddImage();
Ext.Manager3D_Select(0);
selectImage(id);
Ext.Manager3D_Quantif();
Ext.Manager3D_Measure();

Then the Integrated density is 44,394,828 according to the 3D roi manager but 44,397,792 according to the statistics of the 3D object counter.

So my question is which is more accurate ? Why are the results different ?

Thank you very much

Hi @LPUoO,

Actually the two programs will give the same results for volume measurements and hence integrated intensity. The trick is that 3D OC will add the object number inside the image, and 3D Manager will then see two objects, the real object and the object corresponding to the object number, here 1.
If you want to use the output of 3D OC, please do not check the box show numbers.

Best,

Thomas

OC

Hi @ThomasBoudier,
Thank you for your help. So I run again the macro but without the show_numbers as follows:

run("3D Manager");

run("Confocal Series (2.2MB)");
run("Duplicate...", "duplicate channels=2");

id=getImageID()
run("Set 3D Measurements", "volume integrated_density dots_size=5 font_size=10 store_results_within_a_table_named_after_the_image_(macro_friendly) redirect_to=none");
run("3D object counter...", "threshold=67 slice=12 min.=10 max.=4000000 objects statistics");
Ext.Manager3D_AddImage();
Ext.Manager3D_Select(0);
selectImage(id);
Ext.Manager3D_Quantif();
Ext.Manager3D_Measure();

But I still have different results.
The Integrated density is 44,395,973 according to the 3D roi manager but 44,397,792 according to the statistics of the 3D object counter.

Hi @LPUoO,

Humm you are right, this is a bit disturbing, however I noticed this discrepancy will occur only for high value of integrated density. If you increase the threshold to 100 for instance you will get two objects, you will get this discrepancy for the big object, not the small one.

When I look at the code for 3D Objects Counter, I noticed they use float values while I am using double values, so I suspect a numerical error in 3D Objects Counter.

Best,

Thomas

1 Like

ok, thank you for the info !