fit_model | R Documentation |
This function performs MCMC simulation for fitting different types of probit models (binary, multivariate, mixed, latent class, ordered, ranked) to discrete choice data.
fit_model(
data,
scale = "Sigma_1,1 := 1",
R = 1000,
B = R/2,
Q = 1,
print_progress = getOption("RprobitB_progress", default = TRUE),
prior = NULL,
latent_classes = NULL,
fixed_parameter = list(),
save_beta_draws = FALSE
)
data |
An object of class |
scale |
[ |
R |
[ |
B |
[ |
Q |
[ |
print_progress |
[ |
prior |
[ |
latent_classes |
[
The following specifications are used for the weight-based updating scheme:
|
fixed_parameter |
[ See the vignette on model definition for definitions of these variables. |
save_beta_draws |
[ |
An object of class RprobitB_fit
.
prepare_data()
and simulate_choices()
for building an
RprobitB_data
object
update()
for estimating nested models
transform()
for transforming a fitted model
set.seed(1)
form <- choice ~ var | 0
data <- simulate_choices(form = form, N = 100, T = 10, J = 3, re = "var")
model <- fit_model(data = data, R = 1000)
summary(model)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.