Skip to main content

orangemetabo — MetaboAnalyst-Style Statistics for Orange3

Add-on for Orange3 that reproduces the MetaboAnalyst univariate workflow for GC-MS / GC-IMS feature tables (Compound Discoverer exports), as used in the coffee-fermentation study (AK Weller).

Pipeline

Feature Table CSV ──> Preprocess ──> [Filter] ──> Univariate Stats ──> Heatmap
 (2-header, ;)       (Sum-Norm,       (QC)         (ANOVA / Welch /     (Top-N,
                       log2, Imputation,             Kruskal + BH-FDR     Ward cluster,
                       Autoscale/Pareto)             + log2FC + means)     PNG/SVG export)
                                                                           └─> Volcano
                                                                              (log2FC vs -log10 FDR)

Widgets (category Metabo Weller)

Widget Function
Metabo Feature Table Load Compound Discoverer 2-header semicolon CSV; sample×feature Table with group/sample metas; pseudo-replicate (<3 replicates) hint
Metabo Preprocess Optional imputation (min / k-NN) → sum-normalisation → log2 → autoscale (z) / Pareto
Metabo Feature Filter Drop features by missing fraction, zero variance, constant, or below-detection threshold
Metabo Univariate Stats One-way ANOVA, Welch two-sample t-test, or Kruskal-Wallis per feature + Benjamini-Hochberg FDR + log2FC + group means
Metabo Volcano Volcano plot (log2FC vs. −log10 FDR) for a two-group contrast — taken from the Univariate Stats results, or computed from Data alone (Welch t-test + BH-FDR) so Preprocess → Volcano already plots; FDR/|log2FC| thresholds, direction colours, top-N labels, PNG/SVG export; click a point to select a feature (shift-click to add) to see its per-group distribution as a box plot; emits the significant features and the selected features' sample values
Metabo Heatmap Top-N features by p, Ward/Euclidean row clustering, group bar, PNG/SVG export

Correctness

orangemetabo/metabo_core.py is the headless, Qt-free analytics core. The default pipeline (sum-normalise → log2 → autoscale → one-way ANOVA → BH-FDR) reproduces the validated ground truth analysis_CV/cv_anova_alle_97_features.csv exactly: 97/97 features on F, p, and FDR (max abs diff < 5e-5). Reproduce with _test_core.py (core) and _test_e2e.py (all six widgets, offscreen) — both run against the Dropbox ground truth and print 97/97. The volcano contrast is checked to equal the Welch log2FC and the ground-truth log2FC_ANF_vs_WILD column.

Note on the volcano's fold change: it is the difference of the per-group means in the space of the data you feed in. For a real log2 fold change, preprocess with Sum normalisation + log2 and no scaling (Metabo Preprocess → Method "Sum (total area)", log2 on, Scaling "None"). With autoscaled/Pareto data the x-axis is a scaled mean difference (the p-values are unaffected, since the t-test is scale-invariant per feature).

Plot interaction

The plot widgets (Metabo Volcano, Metabo Heatmap) behave like any Orange plot widget:

  • Wheel over the plot zooms around the cursor; drag with the left button pans — no mode to switch on first.
  • ”Reset view” button restores the automatic view; the matplotlib toolbar above each canvas also offers home / zoom-rect / save.
  • Your zoom/pan survives redraws (changing a threshold, selecting a point, …). A plain matplotlib canvas would autoscale on every draw and silently drop the view — PlotCanvas.after_draw() prevents that.
  • Points are clickable at the edges: selection picks the nearest feature within a 12 px radius (an edge point like a max-log2FC hit is no longer glued to the axis spine / unclickable).
  • The volcano legend is draggable; the volcano/box-plot split has a draggable divider.
  • Orange's Save graph / copy-to-clipboard / report entries work (graph_name is set), and the widget window is resizable.

Implementation: orangemetabo/widgets/_plot.py (PlotCanvas: wheel zoom, drag-pan, click selection, view preservation, reset; attach_toolbar, draggable). Orange's own plots are pyqtgraph based and get this for free; the Metabo plots are matplotlib, hence the helper.

Installation

cd orange-metabo-addon
/Applications/Orange.app/Contents/Frameworks/Python.framework/Versions/Current/bin/python3 -m pip install -e .

Or from the monorepo: python ../orange-install.py metabo.

Metadata

Release files for orangemetabo 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for orangemetabo 0.4.1
File Size Uploaded
orangemetabo-0.4.1.tar.gz 27.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for orangemetabo 0.4.1
File Interpreter ABI Platform
orangemetabo-0.4.1-py3-none-any.whl Python 3 none any Details

Total release size: 60.7 kB

Release files / orangemetabo-0.4.1.tar.gz

Download URL orangemetabo-0.4.1.tar.gz
Size 27.6 kB
Tags Source
SHA-256 checksum
How to use checksums
8d4f2f2c43c727b3cbe0452c4d85ee6315161fc5fb571dd5245c4954886285ed
BLAKE2b-256 checksum
How to use checksums
02cf4e3f11b7290f9bdb288870532a92ed4c48841dc1d71d302cdaab3783d765
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.8

Release files / orangemetabo-0.4.1-py3-none-any.whl

Download URL orangemetabo-0.4.1-py3-none-any.whl
Size 33.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f5c0f474f8119437f9bb96724aece95f1864843c3ab3e5ebc36fe6f91cf14a24
BLAKE2b-256 checksum
How to use checksums
3a3c6fa70c7b9d1e2aaa255452c7e6c6d8432a581dc03e445bcc172bb6f7efc8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.8

Release history Release notifications | RSS feed

0.4.3

2 release files

0.4.2

2 release files

This release

0.4.1 This release

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page