intoNbins: Split a GRanges into N bins

Description Usage Arguments Value Examples

View source: R/matrix.R

Description

Originally posted by Martin Morgan: https://stat.ethz.ch/pipermail/bioconductor/2012-September/047923.html

Usage

1
intoNbins(gr, n = 10)

Arguments

gr

A GRanges with only one seqnames value.

n

Number of bins to produce.

Value

A GRanges object splitted into N bins

Examples

1
2
  gr <- GRanges("chr1", IRanges(c(100, 300), c(200, 500))
  gr <- intoNbins(gr)

CharlesJB/hmwrap documentation built on March 19, 2018, 4:08 a.m.