print_PCA: print_PCA: prints a part of PCA output (sorted)

View source: R/plot_PCA.R

print_PCAR Documentation

print_PCA: prints a part of PCA output (sorted)

Description

The output of the PCA function of the FactoMineR package is an object that contains various matrices. The function print.PCA of that package gives an overview of the available matrices. The function print_PCA displays a sorted version of one of these matrices. With this it is easier to check which variables or individuals play a large role for a certain dimension or pair of dimensions.

Usage

print_PCA(
  res,
  var_ind = "ind",
  measure = "contrib",
  decreasing = T,
  absolute = T,
  dim = 1
)

Arguments

res

Structure that is the output of the function PCA

var_ind

Character string that indicates if output for variables (var) or individuals (ind) will be printed. Default: 'ind'

measure

Character string with the name of the matrix. Possible values are 'coord', 'cor', 'cos2', 'contrib' and 'dist'. Default: 'contrib'

decreasing

Boolean indicating that greatest values come first (TRUE) or smallest values come first (FALSE). Default: TRUE

absolute

Boolean indicating that that absolute values will be sorted: TRUE means take absolute value and FALSE means leave value asis. (Only relevant for measurer='coord'). Default: TRUE

dim

Integer (or vector of two integers) indicating the dimension(s) on which the matrix will be sorted. Default: 1

Examples

## Not run: 
print_PCA(res,var_ind = 'var',decreasing = T,
      dim=1,measure = 'coord',abs=T)

## End(Not run)

HanOostdijk/HOQCutil documentation built on July 28, 2023, 5:56 p.m.