lmerTestContrast: lmerTestContrast

Description Usage Arguments Value

View source: R/lmerTestContrast.R

Description

evaluate model-based comparison given a linear mixed-model as fit by \insertRefKuznetsova2017tidyProt

Usage

1
lmerTestContrast(fm, contrast, df_prior = 0, s2_prior = 0)

Arguments

fm
  • linear mixed model fit by lmerTest::lmer.

contrast
  • a vector indicating a contrast between model coefficients. See the getContrast function to create a contrast.

df_prior
  • prior degrees of freedom for moderated comparison; see also limma::squeezeVar to compute prior degrees of freedom.

s2_prior
  • prior sigma squared for moderated comparison; see also limma::squeezeVar to compute prior sigma squared.

Value

a data.frame containing the result for the comparison and the following columns:

Contrast - indicates the comparison between model coefficients.

log2FC - the fold change estimated from the fit model.

percentControl - the fold-change converted to a percent relative to the control (positive) coefficient.

SE - the standard error of the comparison computed as the square root of the variance.

Tstatistic - the t-statistic for the comparison, calculated using equation (11) from Kuznetsova et al., 2017.

Pvalue - the p-value for the comparison, calculated from the t-value and degrees of freedom using the student's t-distribution, pt.

DF - the degrees of freedom for the comparison.

S2 - sigma squared – the estimated standard deviation of the errors or residual standard deviation (sigma) squared – see also ?sigma.

isSingular - see also lme4::isSingular. If TRUE this indicates that one or more of the model's parameters explains little to no variance.


soderling-lab/tidyProt documentation built on Dec. 23, 2021, 3:31 a.m.