chiDist2 {SNFtool} | R Documentation |
Pairwise Chi-squared distances
Description
Wrapper function chi2Dist imported from 'ExPosition' package. Computes the Chi-squared distances between all pairs of data point given
Usage
chiDist2(A)
Arguments
A |
A data matrix where each row is a different data point |
Value
Returns an N x N matrix where N is the number of rows in X. element (i,j) is the squared Chi-squared distance between ith data point in X and jth data point in X.
Author(s)
Dr. Anna Goldenberg, Bo Wang, Aziz Mezlini, Feyyaz Demir
Examples
## Data1 is of size n x d_1,
## where n is the number of patients, d_1 is the number of genes,
## Data2 is of size n x d_2,
## where n is the number of patients, d_2 is the number of methylation
data(Data1)
data(Data2)
## Calculate distance matrices(here we calculate Euclidean Distance,
## you can use other distance, e.g. correlation)
Dist1 = chiDist2(as.matrix(Data1))
Dist2 = chiDist2(as.matrix(Data2))
[Package SNFtool version 2.3.1 Index]