# Example hierarchical models with 3+ levels of hierarchy?

**URL:** <https://discourse.mc-stan.org/t/example-hierarchical-models-with-3-levels-of-hierarchy/18323>\
**Category:** Modeling\
**Tags:** specification\
**Created:** [October 1, 2020, 11:05am UTC](https://discourse.mc-stan.org/t/example-hierarchical-models-with-3-levels-of-hierarchy/18323 "2020-10-01T11:05:26Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![mike-lawrence](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/mike-lawrence/32/59_2.png) [@mike-lawrence](https://discourse.mc-stan.org/u/mike-lawrence)\
**Post date:** [October 7, 2020, 6:01pm UTC](https://discourse.mc-stan.org/t/example-hierarchical-models-with-3-levels-of-hierarchy/18323/9 "2020-10-07T18:01:22Z")

</div>

Yes, though I think you’ve left off the specification of partial pooling for `district_sigma`.

I’m coding this in raw Stan myself right now (with some more [complexity in design](https://discourse.mc-stan.org/t/partial-pooling-of-correlation-or-covariance-matrices/18474) plus my [reduced-computation trick](https://discourse.mc-stan.org/t/case-study-preview-speeding-up-stan-by-reducing-redundant-computation/14228)), so I’ll post back when I’m done. I am nonetheless still curious if brms can do it out-of-the-box.

---

_[View the full topic](https://discourse.mc-stan.org/t/example-hierarchical-models-with-3-levels-of-hierarchy/18323)._
