Code for Simulating Power for Hierarchical Bayesian models?


I don’t have the real data yet but I am looking to simulate statistical power for a Hierarchical Bayesian Model. Is there existing R (or Python) code for this? Thanks!



What does power mean to you in a Bayesian context? Traditional power is all about detecting a difference from a null hypothesis.

If you want to determine how accurately you can recover a parameter, you can generate data with known parameters from the generative model, and then run Stan on the data and look at the posterior relative to the known simulation.

1 Like