Learn R Programming

fastCorrDiff (version 0.5)

SS: Spectral screening of a differential correlation matrix

Description

The full matrix version of spectral screening method.

Usage

SS(D, K, K.seq = FALSE, sv = FALSE)

Arguments

D

The difference matrix of two correlation/covariance matrices

K

The rank K or the maximum rank K to calculate the spectral scores

K.seq

logical value. If TRUE, then it returns the spectral screening scores for all rank from 1 to K. If FALSE (default), it returns the rank K result

sv

logical value. If TRUE, the square roots of singular values will be used in the score calculation.

Value

R

The the singular vector matrix. Each row is for one variable.

R.sv

The R matrix scaled by sqrt of singular values

score

The spectral score for screening

%% ...

Details

This is the full version spectral screening method, which can be applicable to a few thousands of variables. If a tuning of K is needed, please use the fast.SS for tuning.

References

Tianxi Li, Xiwei Tang, and Ajay Chatrath. Compressed spectral screening for large-scale differential correlation analysis with application in selecting Glioblastoma gene modules. arXiv preprint arXiv:2111.03721, 2021.

See Also

fast.SS

Examples

Run this code
# NOT RUN {
X1 <- matrix(rnorm(200),10,20)
C1 <- cor(X1)
X2 <- matrix(rnorm(200),10,20)
C2 <- cor(X2)

D <- C1-C2

fit <- SS(D, 3, K.seq = FALSE, sv = FALSE)

fit$score

# }

Run the code above in your browser using DataLab