Synthetic example methylation dataset for the comma package
Source:R/comma_example_data.R
comma_example_data.RdA commaData object built from simulated Oxford Nanopore
methylation data. This dataset is used in package examples, vignettes, and
tests. It does not represent real biological data.
Format
A commaData object with:
- Sites
300 methylation sites (200 × 6mA, 100 × 5mC) on a simulated 100 kb chromosome (
"chr_sim").- Samples
3 samples:
ctrl_1andctrl_2(condition"control") andtreat_1(condition"treatment").- Assays
-
methylationBeta values (proportion methylated reads, 0–1).
NAwhere coverage < 5.coverageInteger read depth (10–50 per site).
- rowData
Per-site metadata including
chrom,position,strand,mod_type, andis_diff(ground-truth differential methylation status for testing purposes).- colData
Per-sample metadata:
sample_name,condition,replicate,caller.- genomeInfo
Named integer vector:
c(chr_sim = 100000L).- annotation
5 simulated genomic features (genes, rRNA, tRNA).
- motifSites
Empty
GRanges(no motif search was run).
Value
A commaData object (see Details and Format sections
above for structure).
Details
The dataset simulates an experiment where ~30 of the 200 6mA sites are
differentially methylated between control and treatment conditions. Control
samples have high methylation at these sites (~0.9 beta), while the
treatment sample has low methylation (~0.25 beta). This ground truth is
stored in rowData(comma_example_data)$is_diff for use in testing
diffMethyl() (implemented in Phase 4).
5mC sites are not differentially methylated and serve to test multi- modification-type functionality.
The dataset was generated by data-raw/create_example_data.R using
set.seed(1312).
Examples
data(comma_example_data)
comma_example_data
#> class: commaData
#> sites: 300 | samples: 6
#> mod types: 5mC, 6mA
#> conditions: control, treatment
#> genome: 1 chromosome (100,000 bp total)
#> annotation: 5 features
#> motif sites: none
modTypes(comma_example_data)
#> [1] "5mC" "6mA"
sampleInfo(comma_example_data)
#> sample_name condition replicate caller
#> ctrl_1 ctrl_1 control 1 modkit
#> ctrl_2 ctrl_2 control 2 modkit
#> ctrl_3 ctrl_3 control 3 modkit
#> treat_1 treat_1 treatment 1 modkit
#> treat_2 treat_2 treatment 2 modkit
#> treat_3 treat_3 treatment 3 modkit
dim(methylation(comma_example_data))
#> [1] 300 6