miraesunnykim
change config to full
6f48cad
---
configs:
- config_name: preview
data_files: "preview.parquet"
- config_name: full
data_files:
- split: train
path: "train.parquet"
- split: test
path: "test.parquet"
language:
- en
homepage: https://github.com/ylaboratory/methylation-classification
license: cc-by-4.0
task_categories:
- tabular-classification
tags:
- biology
- bioinformatics
- biomedical
- DNA-methylation
- multi-label-classification
pretty_name: 450k DNA methylation tissue classification
size_categories:
- 10K<n<100K
viewer: true
---
# DNA Methylation Tissue Classification Dataset
## Dataset Summary
- **Homepage:** https://github.com/ylaboratory/methylation-classification
- **Pubmed:** False
- **Public:** True
This data resource is vast, curated reference atlas of DNA methylation (DNAm) profiles
spanning 16,959 *healthy* primary human tissue and cell samples profiled on [Illumina 450K arrays](https://www.illumina.com/documents/products/datasheets/datasheet_humanmethylation450.pdf).
Samples cover 86 unique tissues and cell types and are manually mapped to a common set of terms in the [UBERON anatomical ontology](https://www.ebi.ac.uk/ols4/ontologies/uberon).
This dataset is intended to be used as a baseline resource for multi-label classification in
the biomedical domain, particuarly for tissue/cell‑type classification, deconvolution, and epigenetic biomarker discovery.
> Key stats:
> - **16,959** total DNAm samples from **210** studies in the [Gene Expression Omnibus](https://www.ncbi.nlm.nih.gov/geo/) (GEO)
> - **86** tissue/cell types (55 in training set, 31 in holdout)
> - **297,598** quality controlled CpG sites (M-values) per sample
> - **10,351** samples used for training (>= 2 studies per label)
> - **6,608** samples reserved in holdout set to evalulate generalization/label transfer
## Data and usage
The dataset itself is divided into two sets, one used for training and cross-validation, and a separate holdout set used to for evaluation on unseen labels.
For faster loading and improved performance, the files are stored as [parquet files](https://parquet.apache.org).
For each partition there are two main data types each sample:
- `M-values` (first 297,598 columns): preprocessed and quality controlled DNAm M-values background corrected using [preprocessNoob](https://rdrr.io/bioc/minfi/man/preprocessNoob.html) and normalized using [BMIQ](https://rdrr.io/bioc/wateRmelon/man/BMIQ.html).
- `metadata` (last 5 columns): metadata containing the sample id, dataset, and UBERON tissue/cell identifiers and labels. There are two columns corresponding to UBERON identifiers, one contains the most descriptive tissue or cell term, and the second contains a more general term used to create a larger training compendium. (e.g., `pericardial fat` vs. `visceral fat`).
The full list of files include:
- `train.parquet`: M-values for samples in train partition
- `test.parquet`: M-values for samples in test partition
- `metadata.parquet`: metadata for all samples
- `preview.parquet`: subset of `train.parquet` for datacard preview
Mvalue files are structured samples (rows) by probes (columns). Rows are labeled with GSM identifiers, and columns are labeled with Illumina CpG IDs (e.g., `cg03128332`).
The columns in metadata:
- `training.ID`: standardized UBERON ID used for training
- `training.Name`: corresponding tissue/cell name for the training ID
- `Dataset`: dataset identifier in GEO (GSE ID)
- `Original.ID`: manually annotated most descriptive UBERON ID
- `Original.Name`: correpsonding tissue/cell name for original ID
## Quick start
Using python with the `huggingface_hub` and `pyarrow` packages, and the optional `pandas` and `networkx` packages
installed we can quickly get started with this dataset.
```
from datasets import load_dataset
import pyarrow.parquet as pq
import pandas as pd
import networkx as nx
import seaborn as sns
import matplotlib.pyplot as plt
train_mv = load_dataset("ylab/methyl-classification", split="train").to_pandas().set_index('Sample')
test_mv = load_dataset("ylab/methyl-classification", split="test").to_pandas().set_index('Sample')
metadata = load_dataset(
"parquet",
data_files="https://huggingface.co/datasets/ylab/methyl-classification/resolve/main/metadata.parquet"
)['train'].to_pandas().set_index('Sample')
# View the training set metadata
print(metadata.describe())
# Plot m-value density plots for first five samples
sns.kdeplot(data=train_mv.iloc[:5].T, common_norm=False)
plt.xlabel("Methylation Value")
plt.ylabel("Density")
plt.title("Methylation Density for 5 Samples")
plt.show()
```
## Code for data processing, analysis, and tissue classification
This dataset, while designed to be standalone, was generated as a part of a larger paper predicting tissue and cell type.
The code for processing the raw data files and conducting the analysis in that paper can
be found on the project [Github](https://github.com/ylaboratory/methylation-classification).
## Citation
If you use this dataset in your work, please cite:
> Kim, M., Dannenfelser, R., Cui, Y., Allen, G., & Yao, V. (2025). *Ontology‑aware DNA methylation classification with a curated atlas of human tissues and cell types* [Preprint]. bioRxiv. https://doi.org/10.1101/2025.04.18.649618
```
@article{kim2025methylation_atlas,
title = {Ontology-aware DNA methylation classification with a curated atlas of human tissues and cell types},
author = {Kim, Mirae and Dannenfelser, Ruth and Cui, Yufei and Allen, Genevera and Yao, Vicky},
journal = {bioRxiv},
year = {2025},
doi = {10.1101/2025.04.18.649618},
note = {Preprint}
}
```
## License
This dataset is released under CC BY 4.0, permitting both academic and commercial use with attribution.