# Segment Statistics Volume Calculation

**URL:** <https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252>\
**Category:** Support\
**Tags:** segmentation, volume\
**Created:** [June 21, 2018, 12:12am UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252 "2018-06-21T00:12:42Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![sboebin](https://avatars.discourse-cdn.com/v4/letter/s/f0a364/32.png) [@sboebin](https://discourse.slicer.org/u/sboebin)\
**Post date:** [June 21, 2018, 12:12am UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/1 "2018-06-21T00:12:42Z")

</div>

Hello, I am new to Slicer and have a few questions about the Segment Statistics Module, particularly how it calculates volume. I am currently segmenting muscle groups, subcutaneous and intramuscular fat within a single slice from MR Images of the thigh. I have read that the Labelmap Statistics calculates volume as the product of the pixel spacing (mm3) and the pixel count. I am curious if Slicer is using the actual pixel dimensions given in the DICOM header combined with the slice thickness or not. I cannot find anything on this from the user manual, so I am looking here for help.

Also for the output of segmentation, is it normalized to total volume? Or is it an absolute volume?

I have attached a photo that I hope will better illustrate the issue I am having.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/1/a/1a2143311ed9f7482d5702ed5c497856da9354f1.png)

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 21, 2018, 12:17am UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/2 "2018-06-21T00:17:19Z")

</div>

> [@sboebin](#):
>
> I am curious if Slicer is using the actual pixel dimensions given in the DICOM header combined with the slice thickness or not.

Yes, of course, the volume computation is correct, it takes into account pixel size, slice spacing, axis directions, etc.

> [@sboebin](#):
>
> Also for the output of segmentation, is it normalized to total volume? Or is it an absolute volume?

It is an absolute volume, not relative or normalized.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 21, 2018, 12:19am UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/3 "2018-06-21T00:19:35Z")

</div>

Of course, if you segment a single slice then you will have the volume of a single slice. You can get a full 3D segmentation by using for example “Fill between slices” or “Grow from seeds” effect.

---

<div class="post-metadata">

**Author:** ![sboebin](https://avatars.discourse-cdn.com/v4/letter/s/f0a364/32.png) [@sboebin](https://discourse.slicer.org/u/sboebin)\
**Post date:** [June 21, 2018, 2:28pm UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/4 "2018-06-21T14:28:14Z")

</div>

> [@lassoan](#):
>
> > I am curious if Slicer is using the actual pixel dimensions given in the DICOM header combined with the slice thickness or not.
> 
> Yes, of course, the volume computation is correct, it takes into account pixel size, slice spacing, axis directions, etc.
> 
> ![](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/f/0/f04057e1809652b88d3bf2a269c8769ee113a2c3.png) sboebin:
> 
> > Also for the output of segmentation, is it normalized to total volume? Or is it an absolute volume?
> 
> It is an absolute volume, not relative or normalized.

Thank you very much for your response, it was most helpful. I do have an additional question regarding what specific DICOM tags are used for volume calculations (as most DICOM headers contain both nominal pixel size and actual).

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 21, 2018, 3:33pm UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/5 "2018-06-21T15:33:07Z")

</div>

I don’t know what you mean by nominal pixel size. DICOM contains physical pixel size and physical slice position and orientation (PixelSpacing, ImagePositionPatient, ImageOrientationPatient tags) - these define the actual physical geometry and we use these. We are aware that there are other fields (such as slice thickness) that must not be used for geometry computation and we do not use them.

---

<div class="post-metadata">

**Author:** ![Ash\_Alarfaj](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/ash_alarfaj/32/3327_2.png) [@Ash\_Alarfaj](https://discourse.slicer.org/u/Ash_Alarfaj)\
**Post date:** [June 26, 2018, 3:28pm UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/6 "2018-06-26T15:28:49Z")

</div>

I’ve done for many slices by threshold effect because it allow me to correct the mislabel while the grow from seeds effect or fill between slices effects don’t allow me to correct.

---

<div class="post-metadata">

**Author:** ![Ash\_Alarfaj](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/ash_alarfaj/32/3327_2.png) [@Ash\_Alarfaj](https://discourse.slicer.org/u/Ash_Alarfaj)\
**Post date:** [June 26, 2018, 3:43pm UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/7 "2018-06-26T15:43:58Z")

</div>

Hi Iassoan  
It is same my question the pixel size in slicer match the real one in acquired image? because I am trying to measure (cross sectional area,mm2) from pixels number. so pixel dimension not always 1x1x1mm?  
Sincerely

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 26, 2018, 5:19pm UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/8 "2018-06-26T17:19:09Z")

</div>

> [@Ash\_Alarfaj](#):
>
> grow from seeds effect or fill between slices effects don’t allow me to correct

Both Grow from seeds and Fill between slices effect allow dynamic updates (if you change seeds or slice intersections, the full 3D segmentation is recomputed immediately).

> [@Ash\_Alarfaj](#):
>
> my question the pixel size in slicer match the real one in acquired image

You can find the voxel size in Volumes module / Volume information section / Image spacing field.

---

<div class="post-metadata">

**Author:** ![Ennio\_Russo\_Clarisci](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/ennio_russo_clarisci/32/15711_2.png) [@Ennio\_Russo\_Clarisci](https://discourse.slicer.org/u/Ennio_Russo_Clarisci)\
**Post date:** [July 4, 2022, 7:59am UTC](https://discourse.slicer.org/t/segment-statistics-volume-calculation/3252/9 "2022-07-04T07:59:31Z")

</div>

Dear Andras Lasso,

when calculating the mean, median, max, min HU value of a segment, does Slicer 3d consider also the surface of that segment?

Thnak you in adavance  
Ennio
