Saving factor scores from factor analysis

statistics
factors

#1

data_cor <- cor(data)

library(psych)

data_cor_rotated <- fa(r = data_cor, nfactors = 2, fm="pa", rotate="oblimin")

Suppose I wanted to save the 2 factor scores from this factor analysis, in order to carry out data analysis (e.g. descriptive statistics and plots) to evaluate the relationship between these estimated factors and another (composite) variable in the dataset. What would be the Rcode for this?
Thank you


#2

Could you share some reproducible example ? I am not familiar with factor analysis.