Skip to content

Scripting

LEAF targeted analyses can be run without the web UI in two ways:

TaskInterface
Drive analyses from a terminal — schedule, batch, integrate with shell pipelinesThe leaf command-line interface
Embed LEAF in Python pipelines (Snakemake, Nextflow, custom scripts, notebooks)The leaf Python package

Both interfaces operate on the same targeted result format as the web UI: a .msd produced by the UI loads in a script, and vice versa.

When to script vs use the UI

Web UI recommended forScripted interface recommended for
Performing exploratory or interactive analysisRunning batch analyses on many datasets with shared parameters
Reviewing peak quality and adjusting integrations manuallyReproducing an analysis as part of a manuscript or pipeline
Producing visualizations for inspectionIntegrating LEAF results with downstream Python tools (pandas, scikit-learn, etc.)
One-off or ad hoc workEmbedding LEAF in a multi-step workflow

Where to start

  • leaf webui — start the web UI from a terminal (most common)
  • leaf targeted — targeted extraction headless
  • leaf watch — auto-extract new LC-MS files as they land in a folder
  • Python recipes — common scripted-analysis tasks
  • SEED — the Rust reader powering LEAF on macOS / Linux

LEAF is developed by the Morscher Lab.