knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "inst/figures/README-",
  out.width = "100%"
)

planet

DOI r badger::badge_last_commit("GuangchuangYu/badger") Lifecycle: stable R-CMD-check

planet is an R package for inferring ethnicity (1), gestational age (2), and cell composition (3) from placental DNA methylation data.

See full documentation at https://victor.rbind.io/planet

Installation

Latest Bioconductor release

if(!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")
BiocManager::install("planet")

Or the development version of planet:

devtools::install_github('wvictor14/planet')

Usage

See vignettes for more detailed usage.

Example Data

All functions in this package take as input DNAm data the 450k and EPIC DNAm microarray. For best performance I suggest providing unfiltered data normalized with noob and BMIQ. A processed example dataset, plBetas, is provided to show the format that this data should be in. The output of all planet functions is a data.frame.

A quick example of each major function is illustrated with this example data:

library(minfi)
library(planet)

#load example data
data(plBetas)
data(plPhenoData) # sample information

Predict Ethnicity

predictEthnicity(plBetas) %>%
  head()

Predict Gestational Age

There are 3 gestational age clocks for placental DNA methylation data from Lee Y. et al. 2019 (2). To use a specific one, we can use the type argument in predictAge:

predictAge(plBetas, type = 'RPC') %>%
  head()

Predict Cell Composition

Reference data to infer cell composition on placental villi DNAm samples (3) can be used with cell deconvolution from minfi or EpiDISH. These are provided in this package as plCellCpGsThird and plCellCpGsFirst for third trimester (term) and first trimester samples, respectively.

data('plCellCpGsThird')

minfi:::projectCellType(

  # subset your data to cell cpgs
  plBetas[rownames(plCellCpGsThird),], 

  # input the reference cpg matrix
  plCellCpGsThird,

  lessThanOne = FALSE) %>%

  head()

References

  1. Yuan V, Price EM, Del Gobbo G, Mostafavi S, Cox B, Binder AM, et al. Accurate ethnicity prediction from placental DNA methylation data. Epigenetics & Chromatin. 2019 Aug 9;12(1):51.

  2. Lee Y, Choufani S, Weksberg R, Wilson SL, Yuan V, et al. Placental epigenetic clocks: estimating gestational age using placental DNA methylation levels. Aging (Albany NY). 2019;11(12):4238–4253. doi:10.18632/aging.102049

  3. Yuan V, Hui D, Yin Y, Peñaherrera MS, Beristain AG, Robinson WP. Cell-specific characterization of the placental methylome. BMC Genomics. 2021 Jan 6;22(1):6.



wvictor14/plmec documentation built on Feb. 26, 2024, 2:11 p.m.