Applies a chosen rotation (e.g., "varimax") to each cluster's loading matrix
(Lambda[[k]]). Optionally, also rotates the factor scores in
factor_scores[[i]] if they exist and rotate_scores=TRUE.
Usage
rotate_mfa_model(
mfa_fit,
rotation = c("varimax"),
rotate_scores = FALSE,
cluster_ids = NULL
)Arguments
- mfa_fit
A fitted MFA model, typically returned by
mfa_em_fit()orselect_optimal_K_r_mfa()$best_model_info$model, containing:Lambda[[k]]: (M x r) factor loadings for each cluster.factor_scores[[i]]: optional (T_i x r) factor scores for subject i.z[i]: cluster assignments.
- rotation
A string specifying the rotation method. Currently supports
"varimax".- rotate_scores
Logical; if TRUE and
factor_scoresexist, rotate them as well. Iffactor_scoresdo not exist androtate_scores=TRUE, an error or warning is produced.- cluster_ids
Vector of cluster indices to rotate. Defaults to all.