eespca {EESPCA}R Documentation

Eigenvectors from Eigenvalues Sparse Principal Component Analysis (EESPCA)

Description

Computes the first sparse principal component of the specified data matrix using the Eigenvectors from Eigenvalues Sparse Principal Component Analysis (EESPCA) method.

Usage

    eespca(X, max.iter=20, sparse.threshold, lambda.diff.threshold=1e-6, 
        compute.sparse.lambda=FALSE, sub.mat.max.iter=5, trace=FALSE)

Arguments

X

An n-by-p data matrix for which the first sparse PC will be computed.

max.iter

Maximum number of iterations for power iteration method. See powerIteration.

sparse.threshold

Threshold on loadings used to induce sparsity. Loadings below this value are set to 0. If not specified, defaults to 1/sqrt(p).

lambda.diff.threshold

Threshold for exiting the power iteration calculation. If the absolute relative difference in lambda is less than this threshold between subsequent iterations, the power iteration method is terminated. See powerIteration.

compute.sparse.lambda

If true, the sparse loadings will be used to compute the sparse eigenvalue.

sub.mat.max.iter

Maximum iterations for computation of sub-matrix eigenvalues using the power iteration method. To maximize performance, set to 1. Uses the same lambda.diff.threshold.

trace

True if debugging messages should be displayed during execution.

Value

A list with the following elements:

References

See Also

eespcaForK,computeApproxNormSquaredEigenvector, powerIteration

Examples

    set.seed(1)
    # Simulate 10x5 MVN data matrix
    X=matrix(rnorm(50), nrow=10)
    # Compute first sparse PC loadings using default threshold
    eespca(X=X)

[Package EESPCA version 0.7.0 Index]