KnowYourCG (KYCG) is a data interpretation framework for functional DNA methylation analysis. Unlike existing tools that target genes or genomic intervals, KYCG features direct base-level screenings of diverse biological and technical influences, including sequence motifs, transcription factor binding, histone modifications, replication timing, cell-type–specific methylation, and trait associations. Through efficient infrastructure that rapidly screens thousands of knowledgebases, KYCG addresses data sparsity in low-pass or single-cell DNA methylomes, 5-hydroxymethylation (5hmC) profiles, spatial DNA methylation maps, and array-based datasets for EWAS.
This Bioconductor package is KnowYourCG v1, and stays on the 1.x series. KnowYourCG v2 is kycg: the same framework rewritten in C directly on YAME's bit-packed CpG formats, run from the command line rather than from R.
conda install -c zhou-lab -c conda-forge kycg yame
Documentation: https://zhou-lab.github.io/kycg/
Try it online, no install: https://zhouserver.research.chop.edu/knowyourcg/
v2 fetches and verifies its own knowledgebases and screens genome-wide sets without R; its statistics are validated against this package. Use whichever fits your pipeline — v1 if your analysis lives in R and Bioconductor, v2 for command-line and large sequencing work.
Goldberg DC, Fu H, Atkins D, Moyer E, Lee CN, Deng Y, Zhou W. KnowYourCG: Facilitating base-level sparse methylome interpretation. Science Advances 11(43): eadw3027 (2025). https://doi.org/10.1126/sciadv.adw3027
Release version can be installed from Bioconductor
BiocManager::install("knowYourCG")
Development version can be installed from github.
BiocManager::install('zhou-lab/knowYourCG')
The vignettes also load SummarizedExperiment, sesame and gprofiler2, which
BiocManager::install("knowYourCG") does not fetch. To run every example:
BiocManager::install(c("knowYourCG", "SummarizedExperiment", "sesame",
"gprofiler2"))
testEnrichment - Test for enrichment of query in knowledgebase setstestEnrichment2 - Test enrichment from YAME-compressed CG setstestEnrichmentSEA - GSEA-like test for association of categorical
variable against continuous variabletestProbeProximity - Test if query probes share closer genomic
proximity than randomaggregateTestEnrichments - Aggregate test enrichment resultsgetDBs - Get databases by full or partial nameslistDBGroups - List database group namesloadDBs - Load knowledgebase databases from TSV filesbuildGeneDBs - Build gene-probe association databasedbStats - Aggregate methylation over database set featuresannoProbes - Annotate Probe IDs using KYCG databasesKYCG_plotBar - Bar plot of most enriched CG groupsKYCG_plotDot - Dot plot of most enriched CG groupsKYCG_plotEnrichAll - Plot enrichment test resultsKYCG_plotLollipop - Lollipop plot of log(estimate)KYCG_plotManhattan - Manhattan plot for EWAS resultsKYCG_plotMeta - Plot meta gene or other meta genomic featuresKYCG_plotMetaEnrichment - Plot meta gene enrichmentKYCG_plotPointRange - Point range plot for enrichment resultsKYCG_plotSetEnrichment - Plot set enrichmentKYCG_plotVolcano - Volcano plot of -log2(p.value) vs log(estimate)KYCG_plotWaterfall - Waterfall plot of log(estimate)kycgDataCache - Cache KnowYourCG datakycgDataGet - Get KnowYourCG datalinkProbesToProximalGenes - Find genes in genomic proximity to
Infinium probesbedToCg - Convert BED CpG set to YAME .cg format