coord2GR: Converts genomic coordinates into a GRanges object

View source: R/utils.R

coord2GRR Documentation

Converts genomic coordinates into a GRanges object

Description

This function takes a string vector of genomic coordinates and converts it into a GRanges object.

Usage

coord2GR(coordinates)

Arguments

coordinates

A string vector of one or more genomic coordinates to be converted

Details

Genomic coordinates can take one of the following syntax:

  • seqnames:start

  • seqnames:start-end

  • seqnames:start-end/strand

The following examples are considered valid genomic coordinates:

  • "chr1:21535"

  • "chr3:10550-10730"

  • "X:51231-51330/-"

  • "chrM:2134-5232/+"

Value

A GRanges object that corresponds to the given coordinates

Examples

se <- SpliceWiz_example_NxtSE()

coordinates <- rowData(se)$EventRegion

gr <- coord2GR(coordinates)

alexchwong/SpliceWiz documentation built on March 17, 2024, 3:16 a.m.