View source: R/get-info-from-NIW-IA.R
get_categorization_function_from_grouped_ibbu_stanfit_draws | R Documentation |
Returns a categorization function for the first category, based on a set of parameters for the Normal-Inverse-Wishart (NIW) distribution. ms, Ss, kappas, nus, and priors are assumed to be of the same length and sorted the same way, so that the first element of ms is corresponding to the same category as the first element of Ss, kappas, nus, and priors, etc.
get_categorization_function_from_grouped_ibbu_stanfit_draws(fit, ...)
get_categorization_function_from_NIW_ideal_adaptor(model, ...)
get_NIW_categorization_function(
ms,
Ss,
kappas,
nus,
priors = rep(1/length(ms), length(ms)),
lapse_rate = NULL,
lapse_biases = rep(1/length(ms), length(ms)),
Sigma_noise = matrix(0, nrow = if (is.null(dim(Ss[[1]]))) 1 else max(dim(Ss[[1]])),
ncol = if (is.null(dim(Ss[[1]]))) 1 else max(dim(Ss[[1]]))),
noise_treatment = if (is.null(Sigma_noise)) "no_noise" else "marginalize",
logit = FALSE
)
ms |
Means of the multivariate normal distributions over category means. |
Ss |
Scatter matrices of the inverse Wishart distribution over category covariance matrices. |
kappas |
Strength of the beliefs into the distribution over category means. |
nus |
Strength of the beliefs into the distribution over category covariance matrices. |
priors |
Vector of categories' prior probabilities. (default: uniform prior over categories) |
lapse_rate |
A lapse rate for the categorization responses. |
lapse_biases |
A lapse bias for the categorization responses. (default: uniform bias over categories) |
Sigma_noise |
A noise matrix. (default: a 0-matrix) |
noise_treatment |
How should the noise specified in |
logit |
Should the function that is returned return log-odds (TRUE) or probabilities (FALSE)? (default: TRUE) |
A function that takes as input cue values and returns posterior probabilities of the first category, based on the posterior predictive of the cues given the (IBBU-derived parameters for the) categories' m, S, kappa, nu, and prior, as well as the lapse rate.
TBD
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.