makeBins: Split genome into bins

View source: R/utils.R

makeBinsR Documentation

Split genome into bins

Description

This function splid genome into a equaly-sized user defined genomic intervals.

Usage

makeBins(
  bsgenome = NULL,
  fai = NULL,
  chromosomes,
  binsize = 1e+05,
  stepsize = binsize/2
)

Arguments

bsgenome

A reference genome to get lengths of genomic sequences (eg. GRCh38).

fai

A FASTA index to get lengths of genomic sequences.

chromosomes

A user defined set of chromosomes for binning (eg. 'chr1')

binsize

A size of the genomic bin to split genome into.

stepsize

A size of the genomic interval to move each bin. For non-overlapping bins use the same size as binsize.

Value

A GRanges-class object with resized original set of ranges.

Author(s)

David Porubsky


daewoooo/primatR documentation built on Oct. 22, 2024, 9:41 p.m.