High-performance phosphoproteomics analysis toolkit built with Mojo
Features • Installation • Quick Start • Documentation • Contributing • License
PhosphoMojo is a high-performance phosphoproteomics analysis toolkit built with the Mojo programming language. It provides tools for analyzing mass spectrometry data to identify and quantify phosphorylation sites in proteins.
- 🚀 Performance: Leverages Mojo's SIMD vectorization and memory management for blazing-fast analysis
- 🔬 Comprehensive: Complete pipeline from raw data to biological insights
- 🎯 Accurate: Implements state-of-the-art algorithms for site localization
- 📊 Visualizable: Built-in visualization tools for publication-ready figures
- 🔌 Extensible: Modular design for easy customization and extension
-
Mass Spectrometry Data Parsing
- mzML, mzXML, MGF file formats
- Efficient streaming for large files
- Index-based random access
-
Peptide Identification
- Database searching
- In silico digestion
- Score calculation and FDR estimation
-
Phosphorylation Site Localization
- Ascore algorithm
- PTM Score
- PhosphoRS
- Neutral loss analysis
-
Quantitative Analysis
- Label-free quantitation
- TMT/iTRAQ support
- SILAC quantitation
- Multiple normalization methods
-
Statistical Analysis
- Differential phosphorylation
- Multiple testing correction
- Clustering analysis
-
Motif Analysis
- Sequence motif discovery
- Kinase prediction
- Position weight matrices
-
Visualization
- Volcano plots
- Heatmaps
- Sequence logos
- Network plots
- SIMD vectorization for mass calculations
- Parallel processing for database searching
- Memory-efficient data structures
- Streaming processing for large datasets
- Mojo SDK (>= 24.1.0)
- Python (>= 3.9) for Python bindings
# Clone the repository
git clone https://github.com/phosphomojo/phosphomojo.git
cd phosphomojo
# Build the project
mojo build
# Run tests
mojo test# Using mojo package manager
mojo install phosphomojo# Run complete analysis
phosphomojo analyze \
--spectra experiment.mzML \
--database proteins.fasta \
--output results/
# Identify peptides only
phosphomojo identify \
--spectra experiment.mzML \
--database proteins.fasta
# Quantify phosphorylation sites
phosphomojo quantify \
--input phosphosites.txt \
--output quantitation.csv
# Create visualizations
phosphomojo visualize \
--input results.txt \
--type volcano \
--output volcano.pngfrom phosphomojo.api import PhosphoAPI
# Initialize API
api = PhosphoAPI()
# Load data
api.load_spectra("experiment.mzML")
api.load_database("proteins.fasta")
# Run analysis
results = api.analyze()
# Get results
peptides = api.get_peptides()
phosphosites = api.get_phosphosites()
significant = api.get_significant_sites(p_threshold=0.05)
# Export results
api.export_results("output/")from phosphomojo import PhosphoAnalyzer
from phosphomojo.parsers import MzMLParser
# Load spectra
var parser = MzMLParser("experiment.mzML")
var spectra = parser.parse()
# Create analyzer
var analyzer = PhosphoAnalyzer()
_ = analyzer.load_spectra("experiment.mzML")
_ = analyzer.load_database("proteins.fasta")
# Run analysis
var stats = analyzer.run_full_analysis(
"experiment.mzML",
"proteins.fasta"
)
# Print summary
print(analyzer.get_summary())# Download example data
wget https://example.com/phosphomojo_example_data.tar.gz
tar xzf phosphomojo_example_data.tar.gz
# Run analysis
phosphomojo analyze \
--spectra example_data/spectra.mzML \
--database example_data/proteins.fasta \
--output results/from phosphomojo.api import PhosphoAPI
api = PhosphoAPI()
api.load_spectra("experiment.mzML")
api.load_database("proteins.fasta")
api.analyze()
# Define sample groups
control = ["control_1", "control_2", "control_3"]
treatment = ["treatment_1", "treatment_2", "treatment_3"]
# Perform differential analysis
results = api.analyze_differential(control, treatment)
# Get significant sites
significant = api.get_significant_sites(p_threshold=0.05)
print(f"Found {len(significant)} significant sites")from phosphomojo.api import PhosphoAPI
api = PhosphoAPI()
api.load_results("MaxQuant/Phospho (STY)Sites.txt")
# Analyze motifs
motif_results = api.analyze_motifs()
# Predict kinases
for result in motif_results:
print(f"{result.phospho_site}: {result.best_motif}")PhosphoMojo can be configured using TOML configuration files:
# config.toml
[mass_spectrometry]
mass_tolerance = 20.0 # ppm
fragment_tolerance = 0.5 # Da
[peptide_search]
enzyme = "trypsin"
max_missed_cleavages = 2
min_peptide_length = 7
max_peptide_length = 30
[phosphorylation]
localization_threshold = 0.75
phospho_residues = "STY"
[statistics]
p_value_threshold = 0.05
fold_change_threshold = 2.0
multiple_testing_correction = "BH"
[performance]
num_threads = 4
batch_size = 1000| Dataset Size | Spectra | Proteins | Time | Memory |
|---|---|---|---|---|
| Small | 10,000 | 1,000 | 5s | 200MB |
| Medium | 100,000 | 10,000 | 45s | 1.5GB |
| Large | 1,000,000 | 50,000 | 8min | 8GB |
Benchmarks performed on Intel i9-13900K, 64GB RAM
We welcome contributions! Please see our Contributing Guide for details.
# Clone repository
git clone https://github.com/phosphomojo/phosphomojo.git
cd phosphomojo
# Install development dependencies
mojo install --dev
# Run tests
mojo test
# Run linting
mojo lintPlease use the GitHub issue tracker to report bugs or request features.
If you use PhosphoMojo in your research, please cite:
@article{phosphomojo2026,
title={PhosphoMojo: High-performance phosphoproteomics analysis with Mojo},
author={PhosphoMojo Team},
journal={Journal of Proteome Research},
year={2026},
doi={10.1021/acs.jproteome.XXXXXX}
}PhosphoMojo is released under the MIT License.
- Modular for the Mojo programming language
- The open-source proteomics community
- All contributors and users
- Website: https://phosphomojo.io
- Email: [email protected]
- Twitter: @phosphomojo
- GitHub: https://github.com/phosphomojo/phosphomojo
Made with ❤️ by the PhosphoMojo Team
