# Get local maximum when using THStack

**URL:** <https://root-forum.cern.ch/t/get-local-maximum-when-using-thstack/27361>\
**Category:** ROOT\
**Tags:** graphics\
**Created:** [December 22, 2017, 1:58am UTC](https://root-forum.cern.ch/t/get-local-maximum-when-using-thstack/27361 "2017-12-22T01:58:09Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Wile\_E\_Coyote](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/wile_e_coyote/32/12417_2.png) [@Wile\_E\_Coyote](https://root-forum.cern.ch/u/Wile_E_Coyote)\
**Post date:** [December 22, 2017, 9:47am UTC](https://root-forum.cern.ch/t/get-local-maximum-when-using-thstack/27361/3 "2017-12-22T09:47:22Z")

</div>

[Try to play with the histogram that you can get using:](https://root-forum.cern.ch/t/findfirstbinabove-for-thstack/15589/2)

```auto
TH1 *h = ((TH1*)(hs->GetStack()->Last())); // the "SUM"

```

---

_[View the full topic](https://root-forum.cern.ch/t/get-local-maximum-when-using-thstack/27361)._
