cst.stat {st} | R Documentation |
shrinkcat.stat
and shrinkcat.fun
compute
the ``correlation-shared'' t-statistic of Tibshirani and Wassermann (2006).
cst.stat(X, L, verbose=TRUE) cst.fun(L, verbose=TRUE)
X |
data matrix. Note that the columns correspond to variables (``genes'') and the rows to samples. |
L |
vector with class labels for the two groups. |
verbose |
print out some (more or less useful) information during computation. |
The correlation-shared t-statistic for a gene is computed as the average of t-scores correlated with that gene. For mathematical details see Tibshirani and Wasserman (2006).
cst.stat
returns a vector containing correlation-shared t-statistic for each variable/gene.
The corresponding cst.fun
functions return a function that
computes the correlation-shared t-statistic when applied to a data matrix
(this is very useful for simulations).
Korbinian Strimmer (http://strimmerlab.org).
Tibshirani, R., and L. Wasserman. 2006. Correlation-sharing for detection of differential gene expression. See http://arxiv.org/abs/math/0608061 for publication details.
# load st library library("st") # prostate data set data(singh2002) X = singh2002$x L = singh2002$y dim(X) # 102 6033 length(L) # 102 # correlation shared t statistic ## Not run: score = cst.stat(X, L) idx = order(abs(score), decreasing=TRUE) idx[1:10] # [1] 610 1720 364 332 914 3940 4546 1068 579 4331 ## End(Not run) # compared with: # Student t statistic score = studentt.stat(X, L) idx = order(abs(score), decreasing=TRUE) idx[1:10] # [1] 610 1720 364 332 914 3940 4546 1068 579 4331 # for the same example using the shrinkage cat score see shrinkcat.stat()