| Title: | High-Performance Metabolic Flux Analysis from Bulk and Single-Cell RNA-seq Data |
|---|---|
| Description: | A performance-optimized implementation of METAFlux for characterizing cellular metabolism from bulk and single-cell RNA-sequencing data. Uses genome-scale metabolic modeling with Human-GEM to derive 13,082 metabolic fluxes through flux balance analysis (FBA). Features parallel computing, Rcpp acceleration, and optimized algorithms for 10-20x faster computation. |
| Authors: | Zaoqu Liu [aut, cre] |
| Maintainer: | Zaoqu Liu <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 2.2.0 |
| Built: | 2026-05-24 10:18:26 UTC |
| Source: | https://github.com/Zaoqu-Liu/METAFlux |
Bulk test example
bulk_test_examplebulk_test_example
A data frame with 58581 rows and 5 variables
data(bulk_test_example)data(bulk_test_example)
Calculate bootstrap mean expression for single cell data
calculate_avg_exp(myseurat, myident, n_bootstrap, seed)calculate_avg_exp(myseurat, myident, n_bootstrap, seed)
myseurat |
Seurat object. METAFLUX will calculate on "data" slot |
myident |
Seurat idents for grouping.This will be a character string indicating the grouping of the seurat object |
n_bootstrap |
number of bootstrap |
seed |
random seed |
mean expression data
Calculate metabolic reaction scores (MRAS) for 13082 reactions
calculate_reaction_score(data)calculate_reaction_score(data)
data |
gene expression data.1.The gene expression matrix should be gene by sample matrix where row names are human gene names (gene symbols), and column names should be sample names. Please note that METAFLUX does not support other gene IDs. 2.The input gene expression matrix should be normalized (e.g., log-transformed, etc.) before using METAFLUX. METAFLUX will not perform any normalization on expression data. 3.Gene expression data cannot have negative values. |
This default file indicates the nutrients available in the medium. There are total 44 metabolites available. This file can be changed depending on users. We will allow users to define the medium profile based on their knowledge.
cell_mediumcell_medium
A data frame with 44 rows and 2 variables:
stands for name of nutrients available in the medium.
V2 stands for reaction ID of corresponding nutreints
data(cell_medium)data(cell_medium)
Final optimization step for flux calculation
compute_flux(mras, medium)compute_flux(mras, medium)
mras |
metabolic reaction activity scores |
medium |
input medium file which indicates the nutrients available in the medium. We provide 2 general mediums if you have no prior knowledge about your medium: cell line medium and human blood medium if prior knowledge is not available. Please see tutorial for more details. |
Calculated fluxes
Computes metabolic fluxes for single-cell RNA-seq data using community modeling.
compute_sc_flux( num_cell, fraction, fluxscore, medium, parallel = TRUE, n_cores = NULL, use_cpp = TRUE )compute_sc_flux( num_cell, fraction, fluxscore, medium, parallel = TRUE, n_cores = NULL, use_cpp = TRUE )
num_cell |
Integer. Number of cell types or clusters. |
fraction |
Numeric vector. Fraction of each cell type (must sum to 1). |
fluxscore |
Matrix. Metabolic reaction activity scores (MRAS) from bootstrap sampling. |
medium |
Data frame. Medium profile specifying available nutrients. |
parallel |
Logical. Use parallel computing? (default: TRUE) |
n_cores |
Integer. Number of CPU cores (default: NULL = auto-detect, max 8) |
use_cpp |
Logical. Use C++ optimization? (default: TRUE) |
Data frame of metabolic fluxes for single-cell community model.
This default file indicates the nutrients available in the medium. There are total 44 metabolites available. This file can be changed depending on users. We will allow users to define the medium profile based on their knowledge.
human_bloodhuman_blood
A data frame with 44 rows and 2 variables:
stands for name of nutrients available in the human blood.
tands for reaction ID of corresponding nutreints
data(human_blood)data(human_blood)
Human genome-scale metabolic model (Human-GEM) containing reaction, gene, and pathway information for metabolic flux analysis.
human_gemhuman_gem
A data frame with 13,082 rows (reactions) and 16 variables:
Row number
Reaction ID
Reaction name
Stoichiometric equation
Enzyme Commission number
Gene-protein-reaction rule
Lower flux bound
Upper flux bound
Objective function coefficient (1 for biomass)
Cellular compartment
MIRIAM annotations
Metabolic pathway/subsystem
Alternative reaction ID
Additional notes
Literature references
Reaction confidence score
https://github.com/SysBioChalmers/Human-GEM
data(human_gem) head(human_gem)data(human_gem) head(human_gem)
1648 exchange reactions:mathematical representation of uptake/secrete metabolites into the extracellular space
nutrient_lookup_filesnutrient_lookup_files
1648 rows
data("nutrient_lookup_files")data("nutrient_lookup_files")
single cell test seurat object example
sc_test_examplesc_test_example
A toy example containing 350 cells(Tumor and T cells)
data(sc_test_example)data(sc_test_example)