Fast R Functions for Robust Correlations and Hierarchical Clustering
By Peter Langfelder, Steve Horvath. Journal of Statistical Software, 2012
1,185 citations recorded by the source corpus.
Many high-throughput biological data analyses require the calculation of large correlation matrices and/or clustering of a large number of objects. The standard R function for calculating Pearson correlation can handle calculations without missing values efficiently, but is inefficient when applied to data sets with a relatively small number of missing data. We present an implementation of Pearson correlation calculation that can lead to substantial speedup on data with relatively small number of missing entries. Further, we parallelize all calculations and thus achieve further speedup on systems where parallel processing is available. A robust correlation measure, the biweight midcorrelation, is implemented in a similar manner and provides comparable speed. The functions cor and bicor for fast Pearson and biweight midcorrelation, respectively, are part of the updated, freely available R package WGCNA. The hierarchical clustering algorithm implemented in R function hclust is an order n3 (n is the number of clustered objects) version of a publicly available clustering algorithm (Murtagh 2012). We present the package flashClust that implements the original algorithm which in practice achieves order approximately n2, leading to substantial time savings when clustering large data sets.
Subfields: Molecular Biology
View Paper: https://www.semanticscholar.org/paper/1123478f389a30619f5d6a507d6a7e7d647e60f4
How researchers see this paper
The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.
In Molecular Biology
- Peter Langfelder
- Steve Horvath
- Lin Song
- Neelroop Parikshak
- Michael Jeffrey Gandal
- V. Swarup
- Mattan S. Ben-Shachar
- Indrajeet Patil
Citations in the corpus
- Comparison of co-expression measures: mutual information, correlation, and model based indices (2012, methodology): “Second, “bicor” (refer to Materials and Methods for definition and details) is a median based correlation measure, and is more robust than the Pearson correlation but often more powerful than the Spearman correlation [19,20].”
- State of the aRt personality research: A tutorial on network analysis of personality data in R (2015, positive): “Some of the functions rely on procedures originally implemented in packages igraph (Csárdi & Nepusz, 2006), sna (Butts, 2008b), and WGCNA (Langfelder & Horvath, 2008, 2012).”
- Genome-wide changes in lncRNA, splicing, and regional gene expression patterns in autism (2016, positive): “Modules are identified from this dendrogram, which was constructed from a consensus of 100 bootstrapped datasets 51,52 (see Methods).”
- Geographic patterns of co-occurrence network topological features for soil microbiota at continental scale in eastern China (2016, methodology): “The co-occurrence network was inferred based on the Spearman correlation matrix constructed with the WGCNA package (Langfelder and Horvath, 2012).”
- Methods and Algorithms for Correlation Analysis in R (2020, methodology): “It can be used as a robust alternative to other similarity metrics, such as Pearson correlation (Langfelder & Horvath, 2012).”