data(DataFreq) # frequency data set
data <- DataFreq[,2:ncol(DataFreq)]
rownames(data) <- as.character(t(DataFreq[1:nrow(DataFreq),1]))
res <- CA(data = data, "f") # performs CA
print("Is there dependency between rows and columns?"); res$depdata
print("Number of principal coordinates:"); res$numcood
print("Principal coordinates of the rows:"); round(res$mtxX,2)
print("Principal coordinates of the columns:"); round(res$mtxY,2)
print("Inertia of the principal components:"); round(res$mtxAutvlr,2)
Run the code above in your browser using DataLab