makeLogFCs: Calculate log fold changes and associated p-values.

Description Usage Arguments Value Examples

Description

Wrapper for calculating fold changes based on multcomp::glht() object.

Usage

1
makeLogFCs(ht, base = 10, round_to = 2, conf_level = 0.95)

Arguments

ht

An object of class "glht" from multcomp::glht.

base

A numeric value specifying the log based used in the model. Default is 10.

round_to

A numeric value specifying the number of decimal places in percent change columns in result.

conf_level

A numeric value between 0 and 1 for confidence level. Default is .95.

Value

A data frame with est (estimate change), lwr, upr (confidence bounds), contrast (predictor levels being compared), pct_label (text, for plotting labels), pct_fill (numeric, for plotting scales), and a p-value adjusted for multiple comparrisons but multcomp::glht.

Examples

1
2
3
mod <- lm(Sepal.Length ~ 0 + Species, data = iris) # use model with intercept set to 0
ht <- multcomp::glht(mod, linfct = mcp(Species = "Dunnet"))
fcs <- makeLogFCs(ht)

stevehoang/assayr documentation built on May 24, 2019, 7:20 a.m.