This repository provides a Julia implementation of an agent-based model (ABM) for protein aggregation on a 3D face-centered cubic (FCC) lattice. The model captures stochastic monomer movement, conformational switching (Native ↔ AggregateProne), oligomer formation/dissociation, fibril/aggregate growth, macromolecular crowding (optional static spherical obstacles), and an optional oligomer clearance mechanism implemented as stochastic removal.
The repository is organized to support reproducibility and FAIR software practices, including pinned environments, per-run provenance files, analysis workflows, and archived manuscript data.
git clone https://github.com/isagimon/FAIR_Implementation_ABM.git
cd FAIR_Implementation_ABM
julia run_simulation.jlOutputs are written to a timestamped run directory under Data_Collection/ by default (e.g., Data_Collection/Simulation_2025-04-16_11-08-52/).
Each run directory includes provenance artifacts such as:
Simulation_Information.csvInput_Parameters_used.csv
src/FAIR_Implementation_ABM.jl— Julia package entry point (public API)src/Agents.jl— lattice generation and initial agent assignmentsrc/Environment_and_Movement.jl— movement/aggregation dynamics, data collection, and exportrun_simulation.jl— convenience script to activate/instantiate the Julia environment and run one simulationRun_All_Analysis_Scripts.jl— driver script for the full post-simulation analysis workflowAnalysis/— post-simulation analysis scripts and separate analysis environmentdata/— manuscript data used to generate publication figuresData_Collection/— simulation outputs and aggregated analysis resultsInput_Parameters.csv— simulation configurationInput_Parameters_Analysis.csv— analysis configurationUSAGE.md— detailed usage and output descriptionsDATA_DICTIONARY.md— column definitions for output files and manuscript dataCITATION.cff— citation metadata.zenodo.json— Zenodo metadata
The analysis scripts operate on simulation run folders under Data_Collection/ and write aggregated results to Data_Collection/Compare_Simulations/.
Run the full analysis pipeline:
julia Run_All_Analysis_Scripts.jl
Run_All_Analysis_Scripts.jl activates the separate Julia environment defined in Analysis/Project.toml, which keeps plotting and analysis dependencies separate from the core simulation environment.
Key scripts:
Run_All_Analysis_Scripts.jl— master pipeline driverAppend_AggregateProne_and_Native.jl— aggregates Native/AggregateProne counts across runsAppend_Aggregate_and_Oligomer.jl— aggregates Aggregate/Oligomer counts across runsAverage_All_Monomers_vs_Timesteps.jl— plots average counts over timeAppend_Oligomer_Clearance_Data.jl— aggregates cleared-oligomer counts across runsAverage_Oligomers_Cleared_vs_Timesteps.jl— plots average cleared counts over time
The data/ directory contains the ensemble CSV files used to generate the manuscript figures.
data/Figure_3/— monomer-state count datadata/Figure_4/— aggregate-count comparisons with and without oligomer clearancedata/Figure_5/— simulation runtime data
These files are distinct from the example outputs and are intended to preserve the data underlying the publication figures.
Edit Input_Parameters.csv to change:
- lattice size and agent counts
- kinetic probabilities
- number of timesteps
- whether crowding is enabled and its parameters
- output location (
Directory, optional)
Optional environment overrides (useful in HPC/CI):
FAIR_ABM_PARAMETER_FILE— path to an alternate parameter CSV (instead ofInput_Parameters.csv)FAIR_ABM_OUTPUT_DIR— override the output root directory
Per-run outputs are organized automatically, and the parameter file used for a run is copied into the run directory as Input_Parameters_used.csv for provenance.
The model defines 18 FCC nearest-neighbor movement directions plus an explicit "None" option representing no movement during a timestep. This means a monomer may move to one of 18 neighboring FCC positions or remain in place when "None" is sampled.
The core model uses Julia packages defined in:
Project.tomlManifest.toml
Core packages include:
RandomDatesCSVDataFrames
The analysis workflow uses a separate Julia environment defined in:
Analysis/Project.toml
Publication-figure scripts also use Python dependencies pinned in:
Analysis/requirements.txt
This separation keeps plotting and analysis dependencies out of the core simulation environment.
Apache License 2.0. See LICENSE.
- Isabella Gimón
- Conner Sandefur
- Santiago Schnell
Please cite the repository (see CITATION.cff) if you use it in published work.