Skip to content

CMits/ShootBranchingPSoup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Hormonal Regulation of Shoot Branching in Arabidopsis: A PSoup Simulation Study

This repository contains the code and datasets accompanying the publication on computational modelling of hormonal regulation of shoot branching in Arabidopsis thaliana using PSoup — an R package for semi-quantitative simulation of plant signalling networks.

Overview

Shoot branching is a key determinant of plant architecture, regulated by a complex interplay of hormones including auxin, strigolactones (SL), cytokinins (CK), sucrose, abscisic acid (ABA), and gibberellins (GA). We constructed a 32-node knowledge graph encoding these regulatory interactions and used PSoup to simulate the phenotypic outcomes of genetic and hormonal perturbations.

Trained against 79 diverse perturbations including genetic mutations and hormone treatments, the model achieved 84.8% accuracy in predicting branching direction. On an independent test set of 84 perturbations measuring bud release and gene expression, accuracy reached 72.6%.

The repository also provides:

  • A 35-node sucrose-integrated variant that adds Tre6P, HXK1, and bZIP11 to the base network.
  • A random-network benchmark (N = 1000) demonstrating that the biological topology is required for predictive accuracy.
  • A Python port of the PSoup update equations used for downstream analyses, validated against the R reference.

Repository Structure

ShootBranchingPSoup/
├── Scripts/                                # Analysis and simulation scripts
│   ├── PSoup_Training_Code.R               # Model training pipeline (requires PSoup)
│   ├── PSoup_Testing_Code.R                # Model testing pipeline (requires PSoup)
│   ├── nextStep.R                          # Node update equations (32-node model)
│   ├── fig_3_training.py                   # Figure 3 — training per-perturbation comparison
│   ├── fig_4_testing.py                    # Figure 4 — testing per-perturbation comparison
│   └── PSoup_Run/                          # Python-vs-R validation outputs
│       ├── training/outputs/               # validation_report.txt + per-run CSVs
│       └── testing/outputs/
│
├── Dataset/                                # Supplementary datasets (see table)
│   ├── Dataset S1 … S18                    # Knowledge graph, perturbations, results, SBGN
│   ├── Edges.csv                           # Edge list for the 32-node base model
│   └── Suc_integration/                    # Sucrose pathway extension (35-node model)
│       ├── code/
│       │   ├── psoup_simulator.py          # 35-node PSoup simulator (Python)
│       │   ├── run_all.py                  # Run training & testing simulations
│       │   └── run_random_networks.py      # 1000-network random-topology comparison
│       ├── edges.csv                       # 35-node edge list (66 edges: 39 stim, 27 inhib)
│       ├── edges.graphml                   # Same network in GraphML format
│       ├── csv_to_graphml.py               # Edge-list → GraphML converter
│       ├── perturbations/                  # Training & testing perturbation definitions
│       ├── training/                       # Training simulation results + summary.txt
│       ├── testing/                        # Testing simulation results + summary.txt
│       ├── random_networks/                # Random-topology comparison + summary.txt
│       └── V3_summary.txt                  # V3 consensus sucrose vs base comparison

Supplementary Datasets

Dataset Description
S1 Literature review papers used for construction of the knowledge graph
S2 Literature review papers used for extracting training perturbations
S3 Literature review papers used for extracting testing perturbations
S4 Training data — biological consensus for perturbations
S5 Testing data — biological consensus for perturbations
S6 Exogenous supply values for PSoup during training
S7 Genotype values for PSoup during training
S8 Full PSoup simulation results (training set)
S9 Comparison of simulated vs observed bins (training)
S10 Exogenous supply values for PSoup during testing
S11 Genotype values for PSoup during testing
S12 Full PSoup simulation results (testing set)
S13 Comparison of simulated vs observed bins (testing)
S14 Sucrose-integrated training results (35-node model)
S15 Sucrose-integrated testing results (35-node model)
S16 Epistasis analysis (training)
S17 Biological epistasis bins — per-paper rank comparison (CSV)
S18 Benchmark_Model_Original.sbgn — SBGN network diagram (32-node model)

Requirements

R (for PSoup model training and testing)

  • R >= 4.0
  • PSoup R package

Install PSoup from GitHub:

# install.packages("devtools")
devtools::install_github("Brennan-Lab/PSoup")

Python (for analysis scripts, figures, and the sucrose extension)

  • Python >= 3.9
  • pandas, numpy, matplotlib, networkx, openpyxl, scikit-learn

Install Python dependencies:

pip install pandas numpy matplotlib networkx openpyxl scikit-learn

Usage

All scripts use relative paths and should be run from the repository root directory.

Running the PSoup model (R)

The R scripts require the PSoup package installed. The SBGN network diagram defining the shoot branching knowledge graph is included as Dataset/Dataset S18_Benchmark_Model_Original.sbgn.

# Set working directory to repository root
setwd("path/to/ShootBranchingPSoup")

# Training
source("Scripts/PSoup_Training_Code.R")

# Testing
source("Scripts/PSoup_Testing_Code.R")

Generating figures (Python)

# From the repository root
python Scripts/fig_3_training.py          # Figure 3 — training per-perturbation comparison (300 dpi)
python Scripts/fig_4_testing.py           # Figure 4 — testing per-perturbation comparison (300 dpi)

Validation outputs comparing the Python port of the update equations against the R reference are in Scripts/PSoup_Run/.

Sucrose pathway extension (35-node model)

cd Dataset/Suc_integration/code
python run_all.py                         # Run training & testing simulations
python run_random_networks.py             # Random network comparison (1000 networks)

Results Summary

Base 32-node model (V3)

Split Perturbations Correct Accuracy
Training 79 67 84.8%
Testing 84 61 72.6%

35-node sucrose-integrated model (V3 consensus)

Split Base (32-node) Sucrose (35-node)
Training 83.5% (66/79) 73.4% (58/79)
Testing 71.4% (60/84) 70.2% (59/84)

Sucrose training, extended consensus set (87 perturbations = 76 original + 11 new sucrose): 68/87 correct = 78.2% (Cohen's κ = 0.638, MCC = 0.639, macro-F1 = 0.703). The 11 newly added sucrose perturbations are all predicted correctly (100%).

Sucrose testing (135 comparisons): 94/135 correct = 69.6% (κ = 0.521, MCC = 0.531, macro-F1 = 0.684).

Source: Dataset/Suc_integration/V3_summary.txt, training/summary.txt, testing/summary.txt.

Random-network benchmark (N = 1000)

Topology Accuracy Macro-F1
Biological (35-node) 43.7% 0.4387
Random (1000 networks) 27.2% ± 10.3% 0.2438 ± 0.1068

Random networks span 6.9% – 65.5% accuracy; p = 0.080 (79/1000 ≥ biological). The biological wiring is necessary — randomising the edges while preserving the node set and in/out degree distribution does not recover the predictive accuracy.

Source: Dataset/Suc_integration/random_networks/summary.txt.

Python port validation

The Python port of nextStep.R used by the sucrose and random-network analyses was validated against the original R Dataset S8 output: 82.1% (64/78) of training perturbations match the R-derived bin. Mathematical discrepancies on 35/75 Sustained_growth values are attributable to the R PSoup library returning pre-convergence iterations vs Python's strict convergence (1e-8 tolerance); the update equations themselves are a line-by-line port.

Source: Scripts/PSoup_Run/training/outputs/validation_report.txt.

Model Description

The PSoup model represents shoot branching regulation as a signed directed graph. Each node (hormone, transcription factor, or physiological process) is updated iteratively using a standardised semi-quantitative formula:

Regulation type Update formula
Stimulation + Inhibition 2 * mean(stimulators) / (1 + mean(inhibitors)) * genotype
Stimulation only mean(stimulators) * genotype
Inhibition only 2 / (1 + mean(inhibitors)) * genotype

Simulations run until the network reaches a steady state. Phenotypic predictions are derived by comparing the steady-state value of target nodes (e.g. Sustained_growth) between perturbed and wild-type conditions, using a threshold of 0.05 to classify outcomes as increased (+1), unchanged (0), or decreased (-1).

The network topology is defined in Dataset/Dataset S18_Benchmark_Model_Original.sbgn using the Systems Biology Graphical Notation (SBGN) format, which PSoup reads to construct the simulation graph. The node equations for the 32-node base model are defined in Scripts/nextStep.R. The 35-node extended model (with Tre6P, HXK1, bZIP11) is implemented in Dataset/Suc_integration/code/psoup_simulator.py.

Citation

If you use this code or data, please cite:

[Citation details to be added upon publication]

License

This repository is provided for academic and research purposes. Please cite the associated publication when using these materials.

About

Simulation of hormonal regulation of shoot branching in Arabidopsis thaliana using PSoup. Includes the knowledge graph model, supplementary datasets (S1–S13), analysis scripts, and a sucrose pathway extension.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors