createGranges: createGranges

Description Usage Arguments Value Examples

View source: R/utilities.R

Description

a simplified wrapper function to create a GRanges object.

Usage

1
2
createGranges(chrSeqInfo, starts, widths, mcolname = NULL,
  mcolvalues = NULL)

Arguments

chrSeqInfo

a seqinfo object.

starts

the start ranges.

widths

the width of each range.

mcolname

the name for the mcol attribute.

mcolvalues

the values for the mcol attribute.

Value

a GRanges object.

Examples

1
2
3
4
5
6
7
chrSeqInfo <- GenomeInfoDb::Seqinfo(genome="mm9")["chr1"]
starts=sample(seq_len(100), 10)
widths=starts+10;
mcolname <- "z-score";
mcolvalues <- sample(seq_len(100), 10)
chrGR <- createGranges(chrSeqInfo=chrSeqInfo, starts=starts, widths=widths,
              mcolname=mcolname, mcolvalues=mcolvalues)

DEScan2 documentation built on Nov. 8, 2020, 5:01 p.m.