# How to set joint prior for the regression coefficient in hierarchical regression?

**URL:** <https://discourse.mc-stan.org/t/how-to-set-joint-prior-for-the-regression-coefficient-in-hierarchical-regression/30333>\
**Category:** Modeling\
**Tags:** rstan, brms\
**Created:** [February 9, 2023, 6:32pm UTC](https://discourse.mc-stan.org/t/how-to-set-joint-prior-for-the-regression-coefficient-in-hierarchical-regression/30333 "2023-02-09T18:32:34Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![zasdzcc](https://avatars.discourse-cdn.com/v4/letter/z/b9e5f3/32.png) [@zasdzcc](https://discourse.mc-stan.org/u/zasdzcc)\
**Post date:** [February 10, 2023, 3:15pm UTC](https://discourse.mc-stan.org/t/how-to-set-joint-prior-for-the-regression-coefficient-in-hierarchical-regression/30333/3 "2023-02-10T15:15:00Z")

</div>

Thanks for the suggestion. I think I have to lookup stanvar and stan coding in order to implement this hyper-prior. Otherwise, I have to implement in stan code alone instead of using brms package. I think per this post [Initialisation issues when using student-t for hierarchical priors - #5 by paul.buerkner](https://discourse.mc-stan.org/t/initialisation-issues-when-using-student-t-for-hierarchical-priors/24516/5). It seems that stanvar is experimental. I would be better off by hard coding in stan instead.

---

_[View the full topic](https://discourse.mc-stan.org/t/how-to-set-joint-prior-for-the-regression-coefficient-in-hierarchical-regression/30333)._
