Weighted Gene Co-expression Network Analysis (WGCNA) is an unsupervised systems biology method that constructs a scale-free network from gene expression data, identifies modules of highly interconnected genes, and summarizes each module with an eigengene for correlation with external clinical traits.
Glossary
Weighted Gene Co-expression Network Analysis (WGCNA)

What is Weighted Gene Co-expression Network Analysis (WGCNA)?
A systems biology method for identifying clusters of highly correlated genes and relating them to external traits.
Unlike unweighted hard-thresholding approaches, WGCNA applies a soft-thresholding power to the correlation matrix, preserving the continuous nature of co-expression information. This enables the detection of biologically meaningful clusters, hub genes, and network motifs that drive disease phenotypes or treatment responses.
Key Features of WGCNA
Weighted Gene Co-expression Network Analysis (WGCNA) is a powerful computational method for identifying clusters of highly correlated genes, relating these modules to clinical traits, and pinpointing hub genes for biomarker discovery.
Soft Thresholding Power Selection
WGCNA transforms a correlation matrix into an adjacency matrix by raising the absolute correlation to a power β. This soft thresholding emphasizes strong correlations while penalizing weak ones, preserving the continuous nature of the co-expression information. The optimal β is chosen to achieve a scale-free topology, a network property observed in biological systems where a few hub nodes have many connections. The pickSoftThreshold function evaluates multiple powers and recommends the lowest value where the scale-free topology fit index (R²) exceeds 0.8.
Topological Overlap Measure (TOM)
WGCNA uses Topological Overlap to measure gene interconnectedness, not just direct correlation. TOM quantifies the shared neighborhood of two genes—if they are connected to the same set of other genes, their TOM is high. This metric is more robust than correlation alone for detecting functional modules. The resulting TOM dissimilarity matrix (1 - TOM) is used as input for hierarchical clustering, producing a dendrogram where branches represent distinct co-expression modules.
Module Eigengene Summarization
Each identified module is mathematically summarized by its module eigengene (ME), defined as the first principal component of the module's expression matrix. The ME captures the dominant expression pattern of the module, reducing dimensionality from potentially hundreds of genes to a single representative profile. This allows researchers to:
- Correlate entire modules with external clinical traits (e.g., tumor stage, survival time)
- Identify modules significantly associated with phenotypes of interest
- Perform eigengene network analysis to study higher-order relationships between modules
Module-Trait Relationship Analysis
WGCNA directly links co-expression modules to external sample traits by correlating module eigengenes with clinical variables. The output is a heatmap of module-trait associations, displaying correlation coefficients and p-values for each module-trait pair. This reveals which gene clusters are significantly associated with conditions like disease status, treatment response, or patient survival. Gene Significance (GS) measures the correlation of individual genes with a trait, while Module Membership (MM) measures how well a gene represents its module—genes with high GS and MM are prime biomarker candidates.
Intramodular Hub Gene Identification
Within each biologically relevant module, WGCNA identifies hub genes—the most highly connected nodes that are central to the network's structure. Hub genes are defined by high intramodular connectivity (kIM), meaning they have strong co-expression relationships with many other module members. These genes are often:
- Master regulators or transcription factors
- Functionally critical to the module's biological role
- High-priority therapeutic targets Hub gene status is validated by plotting Gene Significance vs. Module Membership; top-right quadrant genes are both trait-relevant and centrally connected.
Module Preservation Across Datasets
WGCNA provides statistical methods to test whether a co-expression module identified in a reference dataset is preserved in an independent test dataset. The modulePreservation function computes Zsummary and medianRank statistics, which assess the conservation of network density and connectivity patterns. A Zsummary > 10 indicates strong preservation, while values < 2 suggest the module is not reproducible. This is critical for validating biomarker modules across independent cohorts before committing to expensive validation studies.
Frequently Asked Questions
Clear, technical answers to the most common questions about Weighted Gene Co-expression Network Analysis, from its core mechanism to practical implementation decisions.
Weighted Gene Co-expression Network Analysis (WGCNA) is a systems biology method that constructs a scale-free network from gene expression data by raising pairwise correlations to a soft-thresholding power, then identifies clusters of highly interconnected genes called modules. The algorithm proceeds through four core stages: first, it computes a pairwise correlation matrix between all genes across samples. Second, it applies a soft-thresholding power β—chosen to maximize the scale-free topology model fit (typically R² > 0.8)—which transforms the correlation matrix into an adjacency matrix, emphasizing strong correlations while penalizing weak ones. Third, it converts the adjacency matrix into a Topological Overlap Matrix (TOM), which measures not just direct correlation but also shared neighborhood connectivity, producing a more robust and biologically meaningful similarity measure. Fourth, it performs hierarchical clustering on the TOM-based dissimilarity (1 - TOM) and uses dynamic tree cutting to identify modules—groups of genes with high topological overlap. Each module is summarized by its module eigengene (the first principal component of the module's expression matrix), enabling correlation with external clinical traits like disease status, survival time, or treatment response. Unlike hard-thresholding approaches that use arbitrary cutoffs, WGCNA's weighted nature preserves the continuous spectrum of co-expression information, making it especially powerful for identifying subtle regulatory relationships and hub genes—the highly connected central nodes within modules that often represent key biological drivers.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Core concepts and complementary methods that form the analytical foundation for weighted gene co-expression network analysis.
Soft Thresholding Power
A critical parameter in WGCNA that transforms the correlation matrix into an adjacency matrix by raising absolute correlations to a power β. This soft thresholding preserves the continuous nature of co-expression information, unlike hard thresholding which dichotomizes connections. The optimal β is chosen to achieve a scale-free topology fit (R² > 0.8), ensuring the network exhibits biologically realistic hub gene structures. The pickSoftThreshold function evaluates multiple powers and plots the scale-free topology model fit against mean connectivity.
Topological Overlap Matrix (TOM)
A robust measure of network interconnectedness that quantifies not just direct correlation between two genes, but also the extent to which they share common network neighbors. TOM is calculated as:
- TOM_ij = (a_ij + Σ_u a_iu * a_uj) / (min(k_i, k_j) + 1 - a_ij) This metric is superior to raw correlation for identifying functional modules because it filters out spurious isolated connections and reinforces densely connected clusters. The resulting dissimilarity (1 - TOM) serves as input for hierarchical clustering.
Module Eigengene (ME)
The first principal component of a gene module's expression matrix, representing the dominant expression pattern of the entire module. The ME serves as a summary profile that:
- Reduces dimensionality from hundreds of genes to a single vector
- Enables correlation with external clinical traits (tumor stage, survival time)
- Identifies modules significantly associated with phenotypes of interest
- Facilitates module–trait relationship heatmaps for intuitive visualization of biologically relevant modules
Gene Significance & Module Membership
Two complementary metrics for prioritizing genes within modules:
- Gene Significance (GS): The absolute correlation between a gene's expression and an external trait. High GS indicates a trait-associated gene.
- Module Membership (MM): The correlation between a gene's expression profile and its module eigengene, also called kME. High MM identifies hub genes that are central to the module's structure. A strong GS–MM correlation validates that the module's internal organization is biologically relevant to the trait, not an artifact.
Module Preservation Analysis
A statistical framework for assessing whether network modules identified in a reference dataset are also present in an independent test dataset. Key statistics include:
- Zsummary score: Values > 10 indicate strong preservation, 2–10 weak-to-moderate, < 2 no preservation
- medianRank: An aggregate ranking across multiple preservation statistics This analysis validates the reproducibility and biological robustness of co-expression modules across cohorts, platforms, or species, distinguishing true biological signals from dataset-specific noise.
Dynamic Tree Cut
An adaptive algorithm for identifying modules from the hierarchical clustering dendrogram of the TOM-based dissimilarity matrix. Unlike static cut methods that slice at a fixed height, dynamic tree cut:
- Adapts to the shape of branches, detecting nested clusters
- Uses a bottom-up merging step to combine highly similar clusters
- Requires parameters like
deepSplit(0–4) controlling sensitivity andminClusterSizesetting the minimum module size This method produces more biologically coherent modules than arbitrary height cutoffs.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us