run_mlwin: run_mlwin

View source: R/run_mlwin.R

run_mlwinR Documentation

run_mlwin

Description

This function calls runMLwiN to estimate the model.

Usage

run_mlwin(
  .dat,
  .model_formula = as.formula("y ~ 1 + (1 | sch_id_1) + (1 | stu_id)"),
  .outcome_dist = c("Normal", "Binomial", "Poisson", "Negbinom", "Unordered Multinomial",
    "Ordered Multinomial", "Multivariate Normal", "Mixed"),
  .mcmc_burn = 100,
  .mcmc_iter = 1000,
  .mcmc_nchains = 1,
  .mm_list = NULL,
  .progress_bar = NULL,
  ...
)

Arguments

.dat

A dataframe produced by generate_data.

.model_formula

A formula object.

.outcome_dist

A string. Defaults to "Normal". See the D argument in runMLwiN.

.mcmc_burn

Numeric. Defaults to 100.

.mcmc_iter

Numeric. Defaults to 1000.

.mcmc_nchains

Numeric. Defaults to 1.

.mm_list

A list. Generated by build_mm_list.

.progress_bar

Internal argument passed from run_sim. If .progress_bar = TRUE in the external run_sim function, then a progress bar will be displayed while executing this code. The arguments in this internal function defaults to NULL.

...

Other parameters passed to the progressor update.

Value

Returns a model object produced by runMLwiN.


tessaleejohnson/corclus documentation built on Oct. 11, 2022, 3:46 a.m.