Getters to retrieve parts of an object.

get_coordinates(x, ...)

get_replications(x, ...)

get_contributions(x, ...)

get_correlations(x, ...)

get_cos2(x, ...)

get_data(x, ...)

get_distances(x, ...)

get_eigenvalues(x)

get_inertia(x, ...)

get_variance(x, ...)

# S4 method for MultivariateAnalysis
dim(x)

# S4 method for MultivariateAnalysis
rownames(x)

# S4 method for MultivariateAnalysis
colnames(x)

# S4 method for MultivariateAnalysis
dimnames(x)

# S4 method for MultivariateAnalysis
get_contributions(x, margin = 1)

# S4 method for MultivariateAnalysis
get_coordinates(x, margin = 1, sup_name = ".sup")

# S4 method for MultivariateBootstrap
get_replications(x, margin = 1)

# S4 method for BootstrapPCA
get_replications(x)

# S4 method for PCA
get_correlations(x, sup_name = ".sup")

# S4 method for MultivariateAnalysis
get_cos2(x, margin = 1, sup_name = ".sup")

# S4 method for MultivariateAnalysis
get_data(x)

# S4 method for MultivariateAnalysis
get_distances(x, margin = 1)

# S4 method for MultivariateAnalysis
get_eigenvalues(x)

# S4 method for MultivariateAnalysis
get_inertia(x, margin = 1)

# S4 method for MultivariateAnalysis
get_variance(x, digits = 2)

# S4 method for PCA
loadings(x)

Arguments

x

An object from which to get element(s) (a CA or PCA object).

...

Currently not used.

margin

A length-one numeric vector giving the subscript which the data will be returned: 1 indicates individuals/rows (the default), 2 indicates variables/columns.

sup_name

A character string specifying the name of the column to create for supplementary points attribution (see below).

digits

An integer indicating the number of decimal places to be used.

Value

get_*() returns a numeric vector or a data.frame.

loadings() returns of a matrix of class stats::loadings.

Details

get_data() returns a data.frame of original data.

get_contributions() returns a data.frame of contributions to the definition of the principal dimensions.

get_coordinates() returns a data.frame of coordinates. An extra column (named after sup_name) is added specifying whether an observation is a supplementary point or not.

get_replications() returns an array of replicated coordinates (see bootstrap()).

get_correlations() returns a data.frame of correlations between variables and dimensions (PCA). An extra column (named after sup_name) is added specifying whether an observation is a supplementary point or not.

get_cos2() returns a data.frame of \(cos^2\) values (i.e. quality of the representation of the points on the factor map). An extra column (named after sup_name) is added specifying whether an observation is a supplementary point or not.

get_eigenvalues() returns a data.frame with the following columns: eigenvalues, variance (percentage of variance) and cumulative (cumulative percentage of variance).

get_variance() returns a numeric vector giving the percentage of explained variance of each dimension.

loadings() returns variable loadings (i.e. the coefficients of the linear combination of the original variables). loadings() is only implemented for consistency with [stats][stats::loadings].

See also

Other mutator: subset()

Author

N. Frerebeau