Skip to contents

Implements a 2-step workflow: fit an initial CAVI model, post-process to obtain covariance components, select factor counts using an eigen-proportion rule, and refit CAVI with the selected K and J_s.

Usage

refit_cavi(Y_list, fit0 = NULL, post_fit0 = NULL, cutoff = 0.05, ...)

Arguments

Y_list

List of S study matrices (each n_s x P).

fit0

Optional initial fit from fit_cavi().

post_fit0

Optional post-processed initial fit from postprocess_cavi(). If both fit0 and post_fit0 are supplied, post_fit0 is used.

cutoff

Eigen-proportion cutoff passed to select_k_from_sigma().

...

Passed to fit_cavi() for the refit.

Value

Post-processed output of the refit (same structure as postprocess_cavi()).