center: Center samples

centerR Documentation

Center samples

Description

Center samples

Usage

center(
  object,
  selector = rep(TRUE, nrow(object)) == TRUE,
  fun = "median",
  verbose = TRUE
)

Arguments

object

SummarizedExperiment

selector

logical vector (length = nrow(object))

fun

aggregation function (string)

verbose

TRUE/FALSE

Value

SummarizedExperiment

Examples

require(matrixStats)
file <- system.file('extdata/fukuda20.proteingroups.txt', package = 'autonomics')
object <- read_maxquant_proteingroups(file)
fdt(object)$housekeeping <- FALSE
fdt(object)$housekeeping[order(rowVars(values(object)))[1:5]] <- TRUE
values(object)[, object$subgroup=='Adult'] %<>% magrittr::add(5)
plot_sample_densities(object)
plot_sample_densities(center(object))
plot_sample_densities(center(object, housekeeping))

bhagwataditya/importomics documentation built on Nov. 28, 2024, 8:28 a.m.