makeEpiTxDbFromGRanges: Create a 'EpiTxDb' object from a 'GRanges' object

View source: R/makeEpiTxDbFromGRanges.R

makeEpiTxDbFromGRangesR Documentation

Create a EpiTxDb object from a GRanges object

Description

makeEpiTxDbFromGRanges extracts informations from a GRanges object. The following metadata columns can be used:

  • mod_id, mod_type, mod_name and tx_ensembl. The first three are mandatory, whereas tx_ensembl is optional.

  • rx_genename, rx_rank, rx_ensembl, rx_ensembltrans and rx_entrezid

  • spec_type, spec_genename, spec_ensembl, spec_ensembltrans and spec_entrezid

  • ref_type and ref

... and passed on the makeEpiTxDb.

Usage

makeEpiTxDbFromGRanges(gr, metadata = NULL, reassign.ids = FALSE)

Arguments

gr

A GRanges object, which contains at least the mandatory columns.

metadata

A 2-column data.frame containing meta information to be included in the EpiTxDb object. This data.frame is just passed to makeEpiTxDb. See makeEpiTxDb for more information about the format of metadata. (default: metadata = NULL)

reassign.ids

= FALSE

Value

a EpiTxDb object.

Examples

library(GenomicRanges)
gr <- GRanges(seqnames = "test",
              ranges = IRanges::IRanges(1,1),
              strand = "+",
              DataFrame(mod_id = 1L,
                        mod_type = "Am",
                        mod_name = "Am_1"))
etdb <- makeEpiTxDbFromGRanges(gr)

FelixErnst/EpiTxDb documentation built on March 31, 2024, 1:21 a.m.