I have a dataset with a mixture of categorical and numeric features. I have used the FAMD function from the FactoMineR package to perform Principal Component Analysis. However, I am unable to figure out a way to extract them into another dataframe, so that I can perform Principal Component Regression. I have attached an image of a subset my data.
#Performing Principal Component Analysis on Mixed Data
library(FactoMineR)
pca = FAMD(train[3:378],ncp=10)
#Displaying the eigen value matrix
pca$eig
I have done the analysis so far. I need to be able to extract my principal components to a dataframe to perform Principal Component Regression. Any help would be appreciated.