# Histogram of volume in regions defined by segments

**URL:** <https://discourse.slicer.org/t/histogram-of-volume-in-regions-defined-by-segments/2236>\
**Category:** Support\
**Created:** [March 4, 2018, 3:11pm UTC](https://discourse.slicer.org/t/histogram-of-volume-in-regions-defined-by-segments/2236 "2018-03-04T15:11:18Z")\
**Posts on this page:** 1\
**Showing post:** 2

<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:** [March 4, 2018, 10:33pm UTC](https://discourse.slicer.org/t/histogram-of-volume-in-regions-defined-by-segments/2236/2 "2018-03-04T22:33:29Z")

</div>

Here is a complete example that does exactly what you need (computes histogram for each region of a volume defined by a segment). It use Mask volume effect of SegmentEditorExtraEffects extension, so you need to install that extension.

> <https://gist.github.com/lassoan/2f5071c562108dac8efe277c78f2620f>

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/4/7/47b47195187995cf668f498f1f9f5557c1285c26.jpeg)

---

_[View the full topic](https://discourse.slicer.org/t/histogram-of-volume-in-regions-defined-by-segments/2236)._
