Installation
Requirements
- Python 3.12 or newer
- A separate virtual environment for your analysis
Runtime dependencies are installed automatically, including anndata / mudata,
polars, scipy, scikit-learn, statsmodels, inmoose, directlfq,
sdrf-pipelines, pyopenms, and plotly.
Install from PyPI
Create and activate an environment, then install the released package:
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install msmu
python -c "import msmu; print('msmu:', msmu.__version__)"
py -m venv .venv
.venv\Scripts\Activate.ps1
python -m pip install --upgrade pip
python -m pip install msmu
python -c "import msmu; print('msmu:', msmu.__version__)"
Use a Python interpreter meeting the requirement above. For a reproducible analysis, record the printed version and pin that version in your environment specification. The published site follows release tags, while repository documentation follows its checkout. Development-only APIs can be ahead of the PyPI release.
Next, follow the DDA-TMT tutorial. To run the notebook interactively in this environment:
python -m pip install jupyterlab
python -m jupyter lab
Open the DDA-TMT notebook in JupyterLab and run its cells in order. It reads
example Sage TMT results and SDRF metadata from URLs, so it needs
network access. It saves dda_tmt_PXD013361_raw.h5mu and dda_tmt_PXD013361.h5mu
in the notebook's working directory. See the plot display requirements below before running it.
Development checkout
To use the APIs described in the dev branch, install that branch explicitly.
Activate a Python >=3.12 virtual environment first, then run:
git clone --branch dev https://github.com/bertis-informatics/msmu.git
cd msmu
python -m pip install -e .
python -c "import msmu; print('msmu:', msmu.__version__)"
git rev-parse HEAD
An editable installation uses this checkout's source. Record its commit as well as the package version; changing the checkout changes the installed code. To reproduce another revision, check out that commit or release tag before installing.
Build and check documentation
From the repository root, in the development environment:
python -m pip install -e ".[dev,docs]"
python -m mkdocs build --strict
python -m pytest tests/test_docs_notebook_links.py
The strict site build and notebook-link checks also run in PR CI.
The site build renders saved notebook outputs
without executing notebooks, so a successful build alone does not validate analysis code.
Use python -m mkdocs serve to inspect navigation, examples, API pages, and figures locally.
Plot display and image export
The DDA-TMT tutorial uses the PNG renderer. PNG/SVG/PDF export through kaleido requires
a compatible Chrome installation; if needed, run plotly_get_chrome in your environment.
Switching to an interactive renderer avoids that requirement for notebook display.
Case-study environments
The Fulcher case study uses
additional RNA, imputation, and multi-omics dependencies. Its environment setup
provides the Python version and a downloadable requirements.txt with pinned
package versions.