Description Usage Arguments Details Value See Also Examples
Find flanking regions to the left or right or upstream or downstream of a Ranges object.
1 2 3 4 5 6 7 | flank_left(x, width = 0L)
flank_right(x, width = 0L)
flank_upstream(x, width = 0L)
flank_downstream(x, width = 0L)
|
x |
a Ranges object. |
width |
the width of the flanking region relative to the ranges in
|
The function
flank_left
will create the flanking region to the left of starting
coordinates in x
, while flank_right
will create the flanking
region to the right of the starting coordinates in x
. The function
flank_upstream
will flank_left
if the strand of rows in x
is
not negative and will flank_right
if the strand of rows in x
is
negative. The function flank_downstream
will flank_right
if the strand of rows in x
is
not negative and will flank_leftt
if the strand of rows in x
is
negative.
By default flank_left
and flank_right
will
ignore strandedness of any ranges, while flank_upstream
and
flank_downstream
will take into account the strand of x
.
A Ranges object of same length as x
.
IRanges::flank()
,
GenomicRanges::flank()
1 2 3 4 5 6 7 8 | gr <- as_granges(data.frame(start = 10:15,
width = 5,
seqnames = "seq1",
strand = c("+", "+", "-", "-", "+", "*")))
flank_left(gr, width = 5L)
flank_right(gr, width = 5L)
flank_upstream(gr, width = 5L)
flank_downstream(gr, width = 5L)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.