View source: R/probitInverse.R
probitInverse | R Documentation |
Transform latent group-level normal distribution (latent-trait MPT) into mean and SD on probability scale.
probitInverse(mu, sigma, fittedModel = NULL)
mu |
latent-probit mean of normal distribution |
sigma |
latent-probit SD of normal distribution |
fittedModel |
optional: fitted traitMPT model. If provided, the
bivariate inverse-probit transform is applied to all MCMC samples (and
|
implied mean and SD on probability scale
####### compare bivariate vs. univariate transformation
probitInverse(mu = 0.8, sigma = c(0.25, 0.5, 0.75, 1))
pnorm(0.8)
# full distribution
prob <- pnorm(rnorm(10000, mean = 0.8, sd = 0.7))
hist(prob, 80, col = "gray", xlim = 0:1)
## Not run:
# transformation for fitted model
mean_sd <- probitInverse(fittedModel = fit)
summarizeMCMC(mean_sd)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.