Description Usage Arguments Details Value Examples
Metagene aggregate from an S3 metagene object.
1 | metagene_aggregate(m, aggregate_fun = "mean", transform_fun = NULL, ...)
|
m |
the object to create the metagene aggregate for |
aggregate_fun |
the function name to aggregate values such as 'events', 'sum', 'mean', 'ttest' (default is 'mean') |
transform_fun |
a function to be applied to vlues before aggregate function is applied. |
... |
other arguments passed to fun |
Aggregates values. transform_fun takes a matrix as input and returns a similar sized matrix. ie log2p1 <- function(m)log2(m+1) aggreagate_fun can be mean, sum, events or t.test or vector containing several of those.
a tibble with column, rel_pos, sample, group, and aggregate values where column name is mean, sum, events or estimate+conf.low+conf.high for ttest
1 2 3 4 5 6 7 | fname <- system.file("extdata", "matrix_grouped.gz", package = "RMetaTools")
m <- load_deeptoolsmatrix3_new(fname)
metagene_aggregate(m)
metagene_aggregate(m, aggregate_fun = 'events')
metagene_aggregate(m, aggregate_fun = 'ttest')
log2p1 <- function(m){log2(m+1)}
metagene_aggregate(m, aggregate_fun = 'mean', transform_fun = log2p1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.