data.frame2GRanges {RnBeads} | R Documentation

## data.frame2GRanges

### Description

Converts a `data.frame` that defines genomic regions to object of type `GRanges`.

### Usage

    data.frame2GRanges(dframe, ids = rownames(dframe),
      chrom.column = "Chromosome", start.column = "Start",
      end.column = "End", strand.column = NULL, assembly = "hg19",
      sort.result = TRUE)

### Arguments

`dframe` | Table defining genomic regions.
`ids` | Region names (identifiers) as a `character` vector, or `NULL` if no names are present.
`chrom.column` | Column name or index that lists the chromosome names.
`start.column` | Column name or index that lists the start positions of the regions.
`end.column` | Column name or index that lists the end positions of the regions.
`strand.column` | Column name or index that lists the strands on which the regions are located. Set this to `NULL` if this region set is not strand-specific.
`assembly` | Genome assembly of interest. See `rnb.get.assemblies` for the list of supported genomes.
`sort.result` | Should the resulting table be sorted

### Value

`GRanges` object encapsulating all well defined regions on supported chromosomes, contained in `dframe`. Columns other that the ones listed as parameters in this function are included as metadata.

### Author(s)

Yassen Assenov

[Package RnBeads version 2.2.0 Index]