getLinearModelWithInteraction: run linear model with interaction between independent...

View source: R/getLinearModelWithInteraction.R

getLinearModelWithInteractionR Documentation

run linear model with interaction between independent variable and specificed interaction variable

Description

run linear model with interaction between independent variable and specificed interaction variable

Usage

getLinearModelWithInteraction(
  .data,
  id,
  key,
  response,
  independentVariable,
  covariates,
  interactionVariable,
  adjustmentMethod = "none",
  ...
)

Arguments

.data

A dataframe

id

A string or numeric column - represents a unique observation within each key/group combination. PersonId, LabId, etc

key

A string or numeric column - key value for dataframe. Statistics will be computed between groups for each key value

response

numeric column - used as response variable in linear model

independentVariable

a string or numeric column used as independent variable in linear model

covariates

vector of features names in the dataset to be added to linear model as covariates

interactionVariable

a string or numeric column in dataset to be added to interaction term with response variable

adjustmentMethod

optional argument specifiying multiple hypothesis correction to apply to linear model result - defaults to "none"

...

dots - accomodate additional arguments when function is called as parent router

Value

dataframe containing resulting p.values for each key/group stat test


cusom/CUSOM.ShinyHelpers documentation built on Oct. 23, 2023, 6:50 a.m.