Calculate cross-correlations with between rows of input matrices

Share:

Description

Calculate cross-correlations with between rows of input matrices

Usage

1
crossCors(X, Y = NULL, method = "pearson")

Arguments

X

a matrix or data.frame

Y

a matrix or data.frame

method

a string specifying the type of correlation, chosen from pearson (default) or spearman.

Value

a list containing matrices of pairwise correlations and their p-values between rows of the input matrices or dataframes.

Author(s)

Sudhir Varma, NCI-LMP, with input checks, support for Spearman's correlation added by VNR.

Examples

1
2
3
drugActData <- exprs(getAct(rcellminerData::drugData))
crossCors(drugActData[c("94600"), ], drugActData[c("727625", "670655"), ])
crossCors(drugActData[c("94600"), ], drugActData[c("727625", "670655"), ], method="spearman")

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.