Dear Stan/Bayesian stats experts,
Suppose i want to compare two parameter posterior distribution, however, the value range of these parameters is restricted to [0,1], therefore i need a inv_logit transform. Should i use the raw(not locate in [0,1]) or the transformed distribution? Should the result be identical? Thanks.
The answer depends on what you mean by “compare”.
For example, because the transformation is monotonic, if
compute the posterior probability that one quantity is larger than another, then it doesn’t matter whether you compare the distributions on the constrained or unconstrained scales (of course you cannot directly compare constrained to unconstrained).
On the other hand, if
compute the posterior distribution of the difference, you will get completely different answers on the different scales.
Regardless of whether the results are the same for the particular comparison you are interested in, you will always be ok if you work on whichever scale (constrained or unconstrained) is meaningful/interpretable to you.