createGranges: createGranges

View source: R/utilities.R

createGrangesR Documentation

createGranges

Description

a simplified wrapper function to create a GRanges object.

Usage

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

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)

drighelli/DEScan2 documentation built on March 21, 2023, 3:06 p.m.