View source: R/GRanges2GRangesList.R
GRanges2GRangesList | R Documentation |
Convert a GRanges
object to a GRangesList
object. The output region set follows the format required by the main permutation test functions.
GRanges2GRangesList(A = NULL)
A |
A |
If input GRanges
object has a metadata named as "group",
ranges having the same group number represent a region. If not, a range is a region.
A region in the input set will be outputted as a list element IN returned
GRangesList
object.
A GRangesList
object.
GRanges2GRangesList
library(GenomicRanges)
GRanges.object <- GRanges(
Rle(c("chr2", "chr2", "chr1", "chr3")),
IRanges(1:4, width = 5)
)
# Assign the first and the second ranges to the same element.
GRanges.object$group <- c(1, 1, 2, 3)
GRangesList.object <- GRanges2GRangesList(GRanges.object)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.