MantelCorrs: Compute Mantel Correlation(s)

Description Usage Arguments Value Warning Note Author(s) References See Also Examples

View source: R/MantelCorrs.r

Description

'MantelCorrs' computes the Mantel correlation between two dissimilarity matrices

Usage

1
MantelCorrs(Dfull, Dsubsets)

Arguments

Dfull

distance matrix returned by 'DistMatrices' using original 'data'

Dsubsets

list of distance matrices from each k cluster or partition returned by 'DistMatrices'

Value

A list with k components

where component i

Mantel correlation for cluster i, i = 1,...,k

Warning

The function is meant to be executed AFTER 'GetClustes' and 'DistMatrices' (see example)

Note

the value 'k' corresponds to the parameter 'num.k' in 'GetClusters'

Author(s)

Brian Steinmeyer

References

Mantel N: The detection of disease clustering and a generalized regression approach. Cancer Research. 27(2), 209-220 (1967).

See Also

'GetClusters' 'DistMatrices' 'kmeans'

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# simulate a p x n microarray expression dataset, where p = genes and n = samples
data.sep <- rbind(matrix(rnorm(1000), ncol=50), matrix(rnorm(1000, mean=5), ncol=50))
noise <- matrix(runif(40000), ncol=1000)
data <- t(cbind(data.sep, noise))
data <- data[1:200, ]
# data has p = 1,050 genes and n = 40 samples

clusters.result <- GetClusters(data, 100, 100)
dist.matrices <- DistMatrices(data, clusters.result$clusters)
mantel.corrs <- MantelCorrs(dist.matrices$Dfull, dist.matrices$Dsubsets)

MantelCorr documentation built on Nov. 8, 2020, 4:58 p.m.