Variance priors

Can you suggest tips for setting priors when modeling the standard deviation:

If you observe the empirical sd varies from ~50-70, how would you set priors on the intercept and slope parameters (model 1). How does your approach change with grouped intercepts and slopes (model 2) and multiple grouped intercepts and slopes (model 3).

model 1: sd= exp( intercept1 + slopex);
model2: sd= exp( intercept1_grouped + slope_grouped
x);
model 3: sd= exp( intercept1_grouped + intercept2_grouped + slope1_groupedx1 + slope2_groupedx2);

-Thanks much

I find things “behave” better if regressions for scale parameters like this are done in a log-variance representation:


vector[n] std_dev = sqrt(exp( intercept + effect*x  ) ) ;

But always best to see directly the implications for your parameterization choice by generating samples from the priors for intercept and effect and doing histograms of the resulting std_dev

1 Like