dstatis.inter: Dual STATIS method (interstructure stage)

View source: R/dstatis.inter.R

dstatis.interR Documentation

Dual STATIS method (interstructure stage)

Description

Performs the first stage (interstructure) of the dual STATIS method in order to describe a data folder, consisting of T groups of individuals on which are observed p variables. It returns an object of class dstatis.

Usage

dstatis.inter(xf, normed = TRUE, centered = TRUE, data.scaled = FALSE, nb.factors = 3,
      nb.values = 10, sub.title = "", plot.eigen = TRUE, plot.score = FALSE,
      nscore = 1:3, group.name = "group", filename = NULL)

Arguments

xf

object of class folder. Its elements are data frames with p numeric columns. If there are non numeric columns, there is an error. The t^{th} element (t = 1, \ldots, T) matches with the t^{th} group.

normed

logical. If TRUE (default), the scalar products are normed.

centered

logical. If TRUE (default), the scalar products are centered.

data.scaled

logical. If TRUE, the data of each group are centered and scaled. The analysis is then performed on the correlation matrices. If FALSE (default), the analysis is performed on the covariance matrices.

nb.factors

numeric. Number of returned principal scores (default nb.factors = 3).

nb.values

numerical. Number of returned eigenvalues (default nb.values = 10).

sub.title

string. If provided, the subtitle for the graphs.

plot.eigen

logical. If TRUE (default), the barplot of the eigenvalues is plotted.

plot.score

logical. If TRUE, the graphs of principal scores are plotted. A new graphic device is opened for each pair of principal scores defined by nscore argument.

nscore

numeric vector. If plot.score = TRUE, the numbers of the principal scores which are plotted. By default it is equal to nscore = 1:3. Its components cannot be greater than nb.factors.

group.name

string. Name of the grouping variable. Default: groupname = "group".

filename

string. Name of the file in which the results are saved. By default (filename = NULL) the results are not saved.

Details

The covariance matrices (if data.scale is FALSE) or correlation matrices (if TRUE) per group are computed. The matrix W of the scalar products between these covariance matrices is then computed.

To perform the STATIS method, see the function DSTATIS of the multigroup package.

Value

Returns an object of class dstatis, that is a list including:

inertia

data frame of the eigenvalues and percentages of inertia.

contributions

data frame of the contributions to the first nb.factors principal components.

qualities

data frame of the qualities on the first nb.factors principal factors.

scores

data frame of the first nb.factors scores of the spectral decomposition of W.

norm

vector of the L^2 norms of the densities.

means

list of the means.

variances

list of the covariance matrices.

correlations

list of the correlation matrices.

skewness

list of the skewness coefficients.

kurtosis

list of the kurtosis coefficients.

Author(s)

Rachid Boumaza, Pierre Santagostini, Smail Yousfi, Gilles Hunault, Sabine Demotes-Mainard

References

Lavit, C., Escoufier, Y., Sabatier, R., Traissac, P. (1994). The ACT (STATIS method). Computational Statistics & Data Analysis, 18 (1994), 97-119.

See Also

print.dstatis, plot.dstatis, interpret.dstatis.

DSTATIS

Examples

data(roses)
rosesf <- as.folder(roses[,c("Sha","Den","Sym","rose")])

# Dual STATIS on the covariance matrices
result1 <- dstatis.inter(rosesf, data.scaled = FALSE, group.name = "rose")
print(result1)
plot(result1)

# Dual STATIS on the correlation matrices
result2 <- dstatis.inter(rosesf, data.scaled = FALSE, group.name = "rose")
print(result2)
plot(result2)

dad documentation built on Aug. 30, 2023, 5:06 p.m.