fit_mvnorm: Fit multivariate normal distribution to data

Description Usage Arguments Value

View source: R/fit_mvnorm.R

Description

Fit multivariate normal distribution to data

Usage

1
2
3
4
fit_mvnorm(dat, niter = 5000, priors = list(), inits = list(),
  nchains = 3, autofit = FALSE, max_attempts = 10,
  keep_samples = Inf, threshold = 1.15, save_progress = NULL,
  progress = NULL)

Arguments

dat

Input data, as a data.frame or matrix

niter

Number of iterations per attempt fitting attempt.

priors

Named list of prior overrides. See gibbs_default_priors() for details.

inits

Named list of initial conditions

nchains

Number of chains (default = 3)

autofit

(Logical) If TRUE, keep re-trying until model has converged (default = FALSE)

max_attempts

Maximum number of attempts for autofit (default = 10)

keep_samples

Maximum number of samples to keep in results (default = Inf)

threshold

Gelman PSRF threshold for convergence (default = 1.15)

save_progress

If not NULL, path to file in which to save current

progress

(Logical) If TRUE, display a progress bar while sampling chain status between fitting attempts. If NULL (default), default to TRUE if using a sequential future::plan and FALSE

parallel

(Logical) Whether or not to run chains in parallel (default = TRUE)

Value

List containing a tidy summary table of the fitted parameters (summary_table), a list of the summary statistics (stats), and the raw MCMC samples as an mcmc.list (samples).


ashiklom/mvtraits documentation built on Sept. 4, 2019, 7:43 a.m.