Description Usage Arguments Details Value See Also Examples
These methods mirror the viewMeans type functions from IRanges for SimpleRleList. They differ in that they work on an RleDataFrame and an IRanges directly and also have a simplify argument. This works out to be faster (computewise) and also convenient.
Still, an RleDataFrame inherits from SimpleRleList, so all of the views functions will work.
1 2 3 4 5 6  rangeSums(x, bounds, na.rm=FALSE, simplify=TRUE)
rangeMeans(x, bounds, na.rm=FALSE, simplify=TRUE, ...)
rangeMins(x, bounds, na.rm=FALSE, simplify=TRUE)
rangeMaxs(x, bounds, na.rm=FALSE, simplify=TRUE)
rangeWhichMins(x, bounds, na.rm=FALSE, simplify=TRUE)
rangeWhichMaxs(x, bounds, na.rm=FALSE, simplify=TRUE)

x 
RleDataFrame 
bounds 
Matrix with two columns or IRanges representing ranges of rows of

na.rm 
Scalar logical. Ignore NAs in calculations? 
simplify 
Scalar logical. Simplify result? If TRUE, the return value will be a
vector or matrix. For a single view, a vector will be
returned. Otherwise a matrix with one row per view and one column per
column of x will be returned. If FALSE, the return value will be a
list of length 
... 
Additional arguments for other methods. 
The "range" name prefixes here serve to differentiate these functions
from the "view" functions. This may change. I will be asking the
IRanges team to add "..." and "simplify" to the "view" methods so that
I can just make additional methods for RleDataFrame
.
With simplify == TRUE
, a vector for single view or a matrix
otherwise. When simplify == FALSE
, a list of vectors length ncol(x) where each element is of length nrows(bounds)
.
RleDataFrame boundingIndicesByChr
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19  df = RleDataFrame(list(a=Rle(1:5, rep(2, 5))), b=Rle(1:5, rep(2, 5)),
row.names=LETTERS[1:10])
mat = matrix(c(1,4,3,5),ncol=2,dimnames=list(c("Gene1","Gene2"),c("start","end")))
bounds = IRanges(start=c(1, 4), end=c(3, 5), names=c("Gene1","Gene2"))
rangeMeans(df,bounds,simplify=FALSE)
rangeMeans(df,bounds,simplify=TRUE)
rangeMeans(df,mat,simplify=TRUE)
rangeMeans(df,bounds)
rangeSums(df,bounds)
rangeMins(df,bounds)
rangeMaxs(df,bounds)
rangeWhichMins(df,bounds)
rangeWhichMaxs(df,bounds)
# RleDataFrame isa SimpleRleList, so all the IRanges view* methods work too:
v = RleViewsList( lapply( df, Views, start=bounds ) )
viewMeans(v)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.