-
-
Notifications
You must be signed in to change notification settings - Fork 121
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Summary:
See title.
Description:
The following are equivalent in the distributions over alpha
and alpha_std
.
parameters {
real alpha_std
...
transformed parameters {
real alpha = mu + sigma * alpha_std;
...
model {
alpha_std ~ normal(0, 1);
...
parameters {
real<offset = mu, multiplier = sigma> alpha;
...
transformed parameters {
real alpha_std = (alpha - mu) / sigma;
...
model {
alpha ~ normal(mu, sigma);
...
The transform is
alpha_unc = (alpha - mu) / sigma
The inverse transform (unconstraining) is
alpha = mu + sigma * alpha_unc
I checked the code in the repo stan-dev/math
and it's applying the right inverse transform and Jacobian. So it's just the doc that's wrong.
Current Version:
v2.23.0
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working