Menu
Introduction
Getting Started
ID Card
Use Cases
Release notes
Technical documentations
Version
Publication date

Mar 9, 2022

Confidentiality
Public
Reactions
1
Share

Context from DEG

TASK
45 times
55.56 %
1 minute, 42 seconds
Typing name :  TASK.gws_gena.ContextFromDEG Brick :  gws_gena

Create a context flux table from differential expression gene (DEG) data and a metabolic network.

This task integrates gene expression data with metabolic network information to generate context-specific flux constraints for metabolic modeling. It evaluates gene-reaction rules in the network using fold change values from DEG analysis to determine appropriate flux bounds for reactions.

Input Requirements

DEG Table

  • Must contain gene identifiers and log2 fold change values
  • Gene IDs should match those used in the metabolic network
  • Default expected columns: 'gene_id' and 'avg_log2FC' (configurable)

Network

  • Metabolic network in JSON format
  • Must contain gene-reaction rules linking genes to reactions
  • Reactions without gene rules are not modified

Algorithm

  1. Gene ID Validation: Checks compatibility between DEG gene IDs and network gene IDs
  2. Boolean Expression Evaluation: For each reaction's gene-reaction rule:
    • Extracts gene IDs from the rule
    • Retrieves corresponding fold change values from DEG data
    • Evaluates boolean logic:
      • OR operations: takes maximum fold change value
      • AND operations: takes minimum fold change value
      • Handles complex nested expressions with parentheses
  3. Flux Constraint Assignment: Based on evaluated fold change:
    • Values below -threshold: assigns "low" flux constraints (typically restrictive)
    • Values above +threshold: assigns "high" flux constraints (typically permissive)
    • Values within threshold: no constraints applied

Configuration Parameters

  • gene_id_column: Column name containing gene identifiers in DEG table
  • log2_fold_change_column: Column name containing fold change values
  • threshold: Minimum absolute fold change to trigger constraint
  • target_high/low: Target flux values for upregulated/downregulated genes. The target of high fluxes can be for example the mean of fluxes in control conditions.
  • lower_bound_high/low: Lower bounds for flux constraints
  • upper_bound_high/low: Upper bounds for flux constraints
  • confidence: Confidence score for all constraints

Outputs

Context Flux Table

Contains flux constraints with columns:

  • id: Reaction identifier
  • target: Target flux value
  • lower_bound: Lower flux bound
  • upper_bound: Upper flux bound
  • confidence_score: Constraint confidence

List of Reactions Modified

Summary table showing which reactions were modified and their flux traceability ("high" or "low")

Gene-Reaction Rule Examples

  • Simple OR: "gene1 or gene2" → max(fold_change_gene1, fold_change_gene2)
  • Simple AND: "gene1 and gene2" → min(fold_change_gene1, fold_change_gene2)
  • Complex: "(gene1 and gene2) or gene3" → max(min(fc1, fc2), fc3)

Notes

  • Reactions without matching genes in DEG data are not constrained
  • Boolean expressions support standard logical operators with proper precedence

Input

DEG
2d excel like table
Network
Metabolic network

Output

Context flux table
2d excel like table
List of reactions modified
2d excel like table

Configuration

gene_id_column

Optional

Type : stringDefault value : converted

log2_fold_change_column

Optional

Type : stringDefault value : avg_log2FC

threshold

Optional Advanced parameter

Type : floatDefault value : 0.25

target_high

Optional Advanced parameter

Type : floatDefault value : 1

lower_bound_high

Optional Advanced parameter

Type : floatDefault value : 0.5

upper_bound_high

Optional Advanced parameter

Type : floatDefault value : 1000

target_low

Optional Advanced parameter

Type : float

lower_bound_low

Optional Advanced parameter

Type : float

upper_bound_low

Optional Advanced parameter

Type : float

confidence

Optional Advanced parameter

Type : floatDefault value : 1
Shine Logo
Technical bricks to reuse or customize

Have you developed a brick?

Share it to accelerate projects for the entire community.