rmsePCAandWALS: Generate a table of root mean square error (RMSE) statistics for principal component analysis (PCA) and
weighted alternating least squares (WALS).
Description
Function rmsePCAandWALS creates table with the RMSE for each variable, for a low-rank
approximation to the correlation matrix obtained by PCA or WALS.
A matrix with one row per variable and four columns for RMSE statistics.
Arguments
R
The correlation matrix
output
A list object with four approximationst to the correlation matrix
digits
The number of digits used in the output
omit.diagonals
Vector of four logicals for omitting the diagonal of the correlation matrix
for RMSE calculations. Defaults to c(FALSE,FALSE,TRUE,TRUE), to include the diagonal
for PCA and exclude it for WALS
Author
Jan Graffelman (jan.graffelman@upc.edu)
References
Graffelman, J. and De Leeuw, J. (2023) Improved approximation and visualization of the correlation matrix. The American Statistician pp. 1--20. tools:::Rd_expr_doi("10.1080/00031305.2023.2186952")