limma_tost: Two one-sided test procedure with 'limma' for statistical...

View source: R/limma_tost.R

limma_tostR Documentation

Two one-sided test procedure with limma for statistical equivalence test

Description

Two one-sided test procedure with limma for statistical equivalence test of one contrast.

Usage

limma_tost(
  object,
  grp = NULL,
  contrast.v,
  tost.lfc,
  design = NULL,
  weights = NA,
  trend = FALSE,
  block = NULL,
  correlation = NULL,
  adjust.method = "BH",
  add.means = !is.null(grp),
  check.names = TRUE
)

Arguments

object

Matrix-like data object containing log-ratios or log-expression values, with rows corresponding to features (e.g. genes) and columns to samples. Must have row names that are non-duplicated and non-empty.

grp

Vector of sample groups. These must be valid variable names in R and the same length as ncol(object).

contrast.v

Named vector of contrasts, passed to makeContrasts.

tost.lfc

Numeric; smallest logFC that could be of interest.

design

Design matrix of the experiment, with rows corresponding to samples and columns to coefficients to be estimated.

weights

Non-negative observation weights. Can be a numeric matrix of individual weights of same size as the object, or a numeric vector of sample weights with length ncol(object), or a numeric vector of gene weights with length equal to nrow(object). Set to NULL to ignore object$weights. weights=NA (with length one) doesn't pass weights to limma.

trend

Logical; should an intensity-trend be allowed for the prior variance? Default is that the prior variance is constant.

block

Vector specifying a blocking variable on the samples. Has length = ncol(object). Must be NULL if ndups > 1.

correlation

Inter-duplicate or inter-technical replicate correlation. Must be given if ndups>1 or !is.null(block).

adjust.method

Method used to adjust the p-values for multiple testing. Options, in increasing conservatism, include "none", "BH", "BY", and "holm". See p.adjust for the complete list of options. A NULL value will result in the default adjustment method, which is "BH".

add.means

Logical indicating if (unweighted) group means per row should be added to the output.

check.names

Logical; should names(grp)==rownames(object) be checked? Ignored if is.null(design) and add.means is FALSE.

Details

length(contrast.v) must be 1. This function is based on limma_contrasts, so see there for more details.

See Also

limma_contrasts.


jdreyf/ezlimma documentation built on April 28, 2024, 1:10 p.m.