cor_dist: Compute pairwise correlation-based distance

Description Usage Arguments Value

Description

Pearson correlation distance for continuous data: d = (1- cor(x_i, x_j))/2 where cor(x_i, x_j) is the correlation between vector x_i and vector x_j.

Usage

1
2
cor_dist(X, method = "pearson", scale = TRUE, base = 1e+06,
  log_trans = TRUE, log_base = 10)

Arguments

X

A data matrix, e.g. gene expression

method

a character string indicating which correlation coefficient is to be computed. One of "pearson" (default), "kendall", or "spearman": can be abbreviated.

scale

A boolean indicating whether to normalize the columns (samples) of the data to the even sum.

base

A numeric value for the shared column sum, if scale is TRUE.

log_trans

A boolean indicating whether to log transform the data prio to distance computation (log(X + 1)). Default is FALSE.

log_base

A number indicating base for log transformation. Default is 10.

Value

A dissimilarity matrix, D.


nlhuong/buds documentation built on May 17, 2019, 3:13 a.m.