BioTransition: Dynamic Network Biomarker Analysis for Critical Transition Detection

Introduction

BioTransition is a comprehensive R/Bioconductor package for detecting critical transitions in biological systems using Dynamic Network Biomarker (DNB) theory. Critical transitions—abrupt shifts between alternative stable states—are ubiquitous in complex biological processes, including:

  • Disease onset and progression
  • Cellular differentiation
  • Developmental transitions
  • Treatment response

Identifying the pre-transition state (tipping point) before an irreversible shift occurs is crucial for early warning and therapeutic intervention.

Theoretical Background

The DNB theory, proposed by Chen et al. (2012), provides a model-free approach to detect early warning signals of critical transitions. The core principle is that a dominant group of molecules (DNB module) exhibits three key characteristics near the tipping point:

  1. Increased variation: Standard deviation (SD) of DNB members increases dramatically
  2. Enhanced correlation: Pearson correlation coefficient (PCC) among DNB members strengthens
  3. Decreased correlation: PCC between DNB members and non-DNB molecules weakens

The composite index (CI) quantifies the transition signal:

\[CI = \frac{\overline{SD_{in}} \cdot \overline{|PCC_{in}|}}{\overline{|PCC_{out}|}}\]

Installation

From Bioconductor

if (!require("BiocManager", quietly = TRUE))
    install.packages("BiocManager")

BiocManager::install("BioTransition")

From GitHub

devtools::install_github("SolvingLab/BioTransition")

Quick Start

library(BioTransition)

Prepare Example Data

For demonstration, we’ll create a simulated expression matrix with three biological states: Normal, Pre-disease, and Disease.

set.seed(42)

# Simulate expression data
n_genes <- 500
n_samples <- 30

# Create expression matrix
expr <- matrix(
  rnorm(n_genes * n_samples, mean = 10, sd = 2),
  nrow = n_genes,
  ncol = n_samples
)
rownames(expr) <- paste0("Gene", 1:n_genes)
colnames(expr) <- paste0("Sample", 1:n_samples)

# Define sample states
sample_info <- data.frame(
  sample_id = colnames(expr),
  state = rep(c("Normal", "PreDisease", "Disease"), each = 10)
)

head(sample_info)
#>   sample_id  state
#> 1   Sample1 Normal
#> 2   Sample2 Normal
#> 3   Sample3 Normal
#> 4   Sample4 Normal
#> 5   Sample5 Normal
#> 6   Sample6 Normal

Run cDNB Analysis

The conventional DNB (cDNB) method is the fastest approach for initial screening:

result_cdnb <- cDNB(
  expr = expr,
  state = sample_info,
  state.levels = c("Normal", "PreDisease", "Disease"),
  cor.method = "pearson",
  variation.method = "sd"
)

# View DNB scores across states
result_cdnb$DNB.score

Run tDNB Analysis

The topological DNB (tDNB) method, developed in this package, leverages network topology and scale-free properties for more robust detection:

result_tdnb <- tDNB(
  expr = expr,
  state = sample_info,
  state.levels = c("Normal", "PreDisease", "Disease"),
  cor.method = "pearson",
  variation.method = "sd",
  min.size = 10,
  max.size = 200
)

# View results
result_tdnb$DNB.score
result_tdnb$DNB.genes

Available Methods

BioTransition implements seven complementary DNB methodologies:

Method Description PPI Required Reference
cDNB Conventional DNB No Chen et al., 2012
tDNB Topological DNB No Liu Z. (this package)
LcDNB Local DNB Yes —
LDNB Landscape DNB Yes Liu et al., 2019
MDNB Module-based DNB Yes Li et al., 2022
TSNMB Time-series network module Yes Zhong et al., 2022
TSLE Time-series leading edge Yes Liu et al., 2020

Methods Requiring PPI Networks

For methods that require protein-protein interaction (PPI) networks, BioTransition provides built-in networks from STRING database:

# Human PPI network
data(ppi_h)
head(ppi_h)
#>      G1   G2 combined_score
#> 1 GOSR1 ARF5            239
#> 2  GGA1 ARF5            594
#> 3 AP3B1 ARF5            395
#> 4 AP1S1 ARF5            553
#> 5 LMAN2 ARF5            292
#> 6  PGLS ARF5            231

# Mouse PPI network
data(ppi_m)
head(ppi_m)
#>      G1    G2 combined_score
#> 1 Gnai3  Rgs4            889
#> 2 Gnai3 Cmtm4            163
#> 3 Gnai3 Arl5a            201
#> 4 Gnai3  Drd2            969
#> 5 Gnai3  Grm8            267
#> 6 Gnai3  Pkd1            194

Example: LcDNB with PPI Network

result_lcdnb <- LcDNB(
  expr = expr,
  state = sample_info,
  state.levels = c("Normal", "PreDisease", "Disease"),
  ppi = ppi_h,  # Use human PPI network
  cor.method = "pearson"
)

Interpreting Results

All DNB methods return a list containing:

  • DNB.score: Composite index (CI) values across all states
  • DNB.genes: Genes identified in the DNB module
  • Additional method-specific outputs

Identifying the Critical State

The state with the highest CI value is identified as the critical (pre-transition) state:

# Find critical state
critical_state <- result_cdnb$DNB.score$State[
  which.max(result_cdnb$DNB.score$CI)
]
print(paste("Critical state:", critical_state))

# Number of DNB genes
print(paste("Number of DNB genes:", length(result_cdnb$DNB.genes)))

Performance Optimization

BioTransition uses C++ implementations via Rcpp for computationally intensive operations:

  • Correlation matrix calculation
  • P-value computation
  • Module scoring

This provides 2-20x speedup compared to pure R implementations.

Session Information

sessionInfo()
#> R version 4.6.1 (2026-06-24)
#> Platform: x86_64-pc-linux-gnu
#> Running under: Ubuntu 26.04.1 LTS
#> 
#> Matrix products: default
#> BLAS:   /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3 
#> LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.32.so;  LAPACK version 3.12.0
#> 
#> locale:
#>  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
#>  [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
#>  [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
#>  [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
#>  [9] LC_ADDRESS=C               LC_TELEPHONE=C            
#> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       
#> 
#> time zone: Etc/UTC
#> tzcode source: system (glibc)
#> 
#> attached base packages:
#> [1] stats     graphics  grDevices utils     datasets  methods   base     
#> 
#> other attached packages:
#> [1] BioTransition_2.1.0 BiocStyle_2.41.0   
#> 
#> loaded via a namespace (and not attached):
#>  [1] cli_3.6.6           knitr_1.52          rlang_1.3.0        
#>  [4] xfun_0.61           otel_0.2.0          jsonlite_2.0.0     
#>  [7] listenv_1.0.0       buildtools_1.0.0    htmltools_0.5.9    
#> [10] maketools_1.3.2     sys_3.4.3           sass_0.4.10        
#> [13] rmarkdown_2.32      evaluate_1.0.5      jquerylib_0.1.4    
#> [16] fastmap_1.2.0       yaml_2.3.12         lifecycle_1.0.5    
#> [19] BiocManager_1.30.27 compiler_4.6.1      codetools_0.2-20   
#> [22] Rcpp_1.1.2          future_1.76.0       digest_0.6.39      
#> [25] R6_2.6.1            parallelly_1.48.0   parallel_4.6.1     
#> [28] magrittr_2.0.5      bslib_0.12.0        tools_4.6.1        
#> [31] globals_0.19.1      cachem_1.1.0

References

  1. Chen L, Liu R, Liu ZP, Li M, Aihara K. (2012). Detecting early-warning signals for sudden deterioration of complex diseases by dynamical network biomarkers. Scientific Reports, 2:342. doi: 10.1038/srep00342

  2. Liu R, Chen P, Chen L. (2019). Single-sample landscape entropy reveals the imminent phase transition during disease progression. National Science Review, 7(7):1175-1185. doi: 10.1093/nsr/nwy162

  3. Li M, Zeng T, Liu R, Chen L. (2022). Detecting tissue-specific early warning signals for complex diseases based on dynamical network biomarkers. The Innovation, 3(5):100364. doi: 10.1016/j.xinn.2022.100364

  4. Zhong J, Han C, Wang Y, Chen P, Liu R. (2022). Identifying the critical state of complex diseases by the novel concept of sample-specific network module biomarker. Journal of Molecular Cell Biology, 14(6):mjac052. doi: 10.1093/jmcb/mjac052

  5. Liu X, Chang X, Liu R, Yu X, Chen L, Aihara K. (2020). Quantifying critical states of complex diseases using single-sample dynamic network biomarkers. Bioinformatics, 36(4):1068-1074. doi: 10.1093/bioinformatics/btz758