Convenience wrapper around compress_posterior() for sccomp fits.
sccomp stores the underlying cmdstanr fit in attr(x, "fit") rather
than x$fit.
compress_sccomp(
sccomp_obj,
method = c("mclust", "mvdens_gmm", "mvdens_kde"),
variables = NULL,
n_components = 3L,
model_name = NULL,
verbose = FALSE,
remove_csvs = FALSE,
...
)An sccomp fit object (with attr(x, "fit") a
CmdStanMCMC).
One of 'mclust', 'mvdens_gmm', 'mvdens_kde'.
See compression_methods().
Optional character vector of parameter names to keep.
If NULL (default) all columns are used.
Integer number of mixture components (used by
"mclust" and "mvdens_gmm"). Default 3.
mclust covariance structure (e.g. "VVV", "EEE",
or a vector of allowed model names). Ignored by other methods.
When NULL (default) poco auto-selects a sensible set: the
spherical and diagonal models c("EII", "VII", "EEI", "EVI", "VEI", "VVI") are used when nrow(draws) <= ncol(draws) so covariances
remain identifiable, otherwise mclust's full default set is used
and BIC picks the best.
Logical; print backend progress. Default FALSE.
Logical; if TRUE, delete the cmdstan CSV files
after compression. Default FALSE.
Additional arguments forwarded to the backend (e.g.
mclust::Mclust()).
A list with compressed and structure (the sccomp object
with attr(x, "fit") cleared). Use reconstruct_sccomp() to rebuild.