View source: R/syncRangesDir.R
syncRangesDir | R Documentation |
This function takes a set of ranges in GRanges-class
or GRangesList-class
object
and return the same ranges in same class object such that total length of plus (direct, '+') and minus (minus, '-') .
oriented ranges meet the user defined 'majority.strand' orientation.
syncRangesDir(ranges, majority.strand = "+", strand.only = FALSE)
ranges |
A |
majority.strand |
A desired majority strand directionality to be reported. |
strand.only |
If set to |
A GRanges-class
or GRangesList-class
object.
David Porubsky
## Define test genomic ranges to synchronize directionality ##
test.gr <- GenomicRanges::GRanges(
seqnames = "test",
ranges = IRanges::IRanges(
start = c(1, 200, 300),
end = c(200, 300, 500)
), strand = c("-", "+", "-")
)
syncRangesDir(ranges = test.gr, majority.strand = "+")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.