getFlanks-methods: Get upstream and downstream adjacent regions to a genomic...

Description Usage Arguments Value Examples

Description

The function returns flanking regions on either side of a genomic feature. It is useful for getting flanking regions such as CpG island shores.

Usage

1
  getFlanks(grange,flank=2000,clean=T)

Arguments

grange

GRanges object for the feature

flank

number of basepairs for the flanking regions

clean

If set to TRUE, flanks overlapping with other main features will be trimmed, and overlapping flanks will be removed this will remove multiple counts when other features overlap with flanks

Value

GRanges object for flanking regions

Examples

1
2
3
4
5
6
# read the bed file as GRanges object
bed.file=system.file("extdata", "cpgi.hg18.bed.txt", package = "methylKit")
bed.gr=read.bed(location=bed.file,remove.unsual=TRUE)

# get flanks on the either side
bed.flanks=getFlanks(bed.gr,flank=2000,clean=TRUE)

fortunatobianconi/methylkit documentation built on May 16, 2019, 1:51 p.m.