rospca (version 1.0.4)

zeroMeasure: Zero measure

Description

Compute the average zero measures and total zero measure for a list of matrices.

Usage

zeroMeasure(Plist, P, prec = 10^(-5))

Value

A list with components:

measure

Numeric matrix of size \(p\) by \(k\) containing the average zero measure over all length(Plist) simulations for each element of P.

index

Numeric vector containing the indices of all data sets where the estimate was wrong (at least one of the zero measures for the elements of an estimated loadings matrix is equal to 0).

total

Total zero measure, i.e. the average zero measure over all elements of an estimated loadings matrix and over all estimated loadings matrices.

Arguments

Plist

List of estimated loadings matrices or a single estimated loadings matrix. All these matrices should be numeric matrices of size \(p\) by \(k\).

P

True loadings matrix, a numeric matrix of size \(p\) by \(k\).

prec

Precision used when determining if an element is non-zero, default is \(10^{-5}\). We say that all elements with an absolute value smaller than prec are ``equal to zero''.

Author

Tom Reynkens

Details

The zero measure is a way to compare how correctly a PCA method estimates the sparse loadings matrix P. For each element of an estimated loadings matrix, it is equal to one if the estimated and true value are both zero or both non-zero, and zero otherwise. We then take the average zero measure over all elements of an estimated loadings matrix and over all estimated loadings matrices which we call the total zero measure.

References

Hubert, M., Reynkens, T., Schmitt, E. and Verdonck, T. (2016). ``Sparse PCA for High-Dimensional Data with Outliers,'' Technometrics, 58, 424--434.

Examples

Run this code
P <- cbind(c(1,1), c(0,1))
Plist <- list(matrix(1,2,2), P)

zeroMeasure(Plist, P)

Run the code above in your browser using DataLab