Multimodal data
Project description
MuData – multimodal data
Documentation | Publication | Changelog
For using MuData in multimodal omics applications see muon.
Data structure
In the same vein as AnnData is designed to represent unimodal annotated datasets in Python, MuData is designed to provide functionality to load, process, and store multimodal omics data.
MuData
.obs -- annotation of observations (cells, samples)
.var -- annotation of features (genes, genomic loci, etc.)
.obsm -- multidimensional cell annotation,
incl. a boolean for each modality
that links .obs to the cells of that modality
.varm -- multidimensional feature annotation,
incl. a boolean vector for each modality
that links .var to the features of that modality
.mod
AnnData
.X -- data matrix (cells x features)
.obs -- cell metadata (assay-specific)
.var -- annotation of features (genes, peaks, genomic sites)
.obsm
.varm
.uns
.uns
Overview
Input
MuData can be thought of as a multimodal container, in which every modality is an AnnData object:
from mudata import MuData
mdata = MuData({'rna': adata_rna, 'atac': adata_atac})
If multimodal data from 10X Genomics is to be read, convenient readers are provided by muon that return a MuData object with AnnData objects inside, each corresponding to its own modality:
import muon as mu
mu.read_10x_h5("filtered_feature_bc_matrix.h5")
# MuData object with n_obs × n_vars = 10000 × 80000
# 2 modalities
# rna: 10000 x 30000
# var: 'gene_ids', 'feature_types', 'genome', 'interval'
# atac: 10000 x 50000
# var: 'gene_ids', 'feature_types', 'genome', 'interval'
# uns: 'atac', 'files'
I/O with .h5mu files
MuData objects represent modalities as collections of AnnData objects. These collections can be saved to disk and retrieved using HDF5-based .h5mu files, which design is based on .h5ad file structure.
import mudata as md
mdata_pbmc.write("pbmc_10k.h5mu")
mdata = md.read("pbmc_10k.h5mu")
It allows to effectively use the hierarchical nature of HDF5 files and to read/write AnnData object directly from/to .h5mu files:
adata = md.read("pbmc_10k.h5mu/rna")
md.write("pbmc_10k.h5mu/rna", adata)
Citation
If you use mudata in your work, please cite the publication as follows:
MUON: multimodal omics analysis framework
Danila Bredikhin, Ilia Kats, Oliver Stegle
Genome Biology 2022 Feb 01. doi: 10.1186/s13059-021-02577-8.
You can cite the scverse publication as follows:
The scverse project provides a computational ecosystem for single-cell omics data analysis
Isaac Virshup, Danila Bredikhin, Lukas Heumos, Giovanni Palla, Gregor Sturm, Adam Gayoso, Ilia Kats, Mikaela Koutrouli, Scverse Community, Bonnie Berger, Dana Pe’er, Aviv Regev, Sarah A. Teichmann, Francesca Finotello, F. Alexander Wolf, Nir Yosef, Oliver Stegle & Fabian J. Theis
Nat Biotechnol. 2023 Apr 10. doi: 10.1038/s41587-023-01733-8.
mudata is part of the scverse® project (website, governance) and is fiscally sponsored by NumFOCUS. If you like scverse® and want to support our mission, please consider making a tax-deductible donation to help the project pay for developer time, professional services, travel, workshops, and a variety of other needs.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mudata-0.3.3.tar.gz.
File metadata
- Download URL: mudata-0.3.3.tar.gz
- Upload date:
- Size: 323.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0acbd7c3c668fd5fd1e17c2e33bc9fd17df12cea5ea42dc9b8986ad104195a5d
|
|
| MD5 |
fba3df61e7d1dcde491bff38c4fa4d04
|
|
| BLAKE2b-256 |
39c505dc5d98c46ca43e86c084a1fa9babbf1e8b7fd97824b099b54e8969f652
|
Provenance
The following attestation bundles were made for mudata-0.3.3.tar.gz:
Publisher:
release.yaml on scverse/mudata
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mudata-0.3.3.tar.gz -
Subject digest:
0acbd7c3c668fd5fd1e17c2e33bc9fd17df12cea5ea42dc9b8986ad104195a5d - Sigstore transparency entry: 872081143
- Sigstore integration time:
-
Permalink:
scverse/mudata@6887015e5e22aac3ce68a25fdf8874e0bb5b0b17 -
Branch / Tag:
refs/tags/v0.3.3 - Owner: https://github.com/scverse
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@6887015e5e22aac3ce68a25fdf8874e0bb5b0b17 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mudata-0.3.3-py3-none-any.whl.
File metadata
- Download URL: mudata-0.3.3-py3-none-any.whl
- Upload date:
- Size: 43.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
78e9d53ad8e7cd0c6b2aa299665f0bbbd232498fe97058fb5e6e705832e9cdb2
|
|
| MD5 |
51e8d3b894d932d87316cc05bf8b7587
|
|
| BLAKE2b-256 |
040e1420cdc45771800e36fee8f3ff347c247e9d2a7eec7fb3c8e1d6d8b11c50
|
Provenance
The following attestation bundles were made for mudata-0.3.3-py3-none-any.whl:
Publisher:
release.yaml on scverse/mudata
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mudata-0.3.3-py3-none-any.whl -
Subject digest:
78e9d53ad8e7cd0c6b2aa299665f0bbbd232498fe97058fb5e6e705832e9cdb2 - Sigstore transparency entry: 872081158
- Sigstore integration time:
-
Permalink:
scverse/mudata@6887015e5e22aac3ce68a25fdf8874e0bb5b0b17 -
Branch / Tag:
refs/tags/v0.3.3 - Owner: https://github.com/scverse
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yaml@6887015e5e22aac3ce68a25fdf8874e0bb5b0b17 -
Trigger Event:
workflow_dispatch
-
Statement type: