score_features: Score features using ezlimma and score_fcn

Description Usage Arguments Value

View source: R/score_features.R

Description

Score features using limma_contrasts or limma_cor and then applying score_fcn to moderated t-statistics. Does not currently accept type=="mediation".

Usage

1
2
score_features(object, phenotype = NULL, type = c("contrasts",
  "correlation"), contrast.v = NULL, design = NULL, score_fcn = abs)

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 rownames that are non-duplicated and non-empty.

phenotype

Vector of sample characteristics (correlation: numeric; contrasts: character). Should be same length as ncol(object).

type

Type of ezlimma analysis per feauture; must be one of"contrasts" (limma_contrasts), "correlation" (limma_cor), or "mediation" (hitman). You can specify just the initial letter.

contrast.v

Named vector of contrasts, passed to makeContrasts.

design

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

score_fcn

Function that transforms the t-statistics from the contrasts into a non-negative value. Its input must be a vector of same length as number of elements in contrast.v (usually one). Its output must be a non-negative scalar. Ignored if hitman is TRUE.

Value

Named vector of feature scores.


jdreyf/PANTS documentation built on July 18, 2019, 10:12 a.m.