print.PCAOS | R Documentation |
Print results of PCAOS method
## S3 method for class 'PCAOS'
print(x, file = NULL, sep = ";", ...)
x |
an object of class PCAOS |
file |
A connection, or a character string naming the file to print to. If NULL (the default), the results are not printed in a file |
sep |
character string to insert between the objects to print |
... |
further arguments passed to or from other methods |
data (antibiotic)
# Level of scaling of each variable
# Manually
level.scale <- rep(NA,ncol(antibiotic)) #Setting level.scale argument
level.scale[c(3,4)] <- "num"
level.scale[c(6:14)] <- "nom"
level.scale[c(1,15)] <- "ord"
# Or using nature.variables()
level.scale <- rep(NA,ncol(antibiotic))
res.nature <- nature.variables(antibiotic)
level.scale [res.nature$p.numeric] <- "num"
level.scale [res.nature$p.quali] <- "nom"
#Warning; the ordinal nature of variables can not be detected automaticaly.
level.scale[c(1,15)] <- "ord"
# PCAOS
res.PCAOS <- PCAOS(
data = antibiotic,
level.scale = level.scale,
nb.comp = 2)
print(res.PCAOS)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.