modSummary3: Summary of moderation effect

View source: R/modSummary3.R

modSummary3R Documentation

Summary of moderation effect

Description

Summary of moderation effect

Usage

modSummary3(
  fit,
  X = NULL,
  W = NULL,
  Z = NULL,
  labels = NULL,
  modx.values = NULL,
  mod2.values = NULL,
  rangemode = 2,
  maxylev = 6,
  digits = 3
)

Arguments

fit

An object of class lm

X

Name of independent variable

W

Name of the first moderator variable

Z

Name of the second moderator variable

labels

Optional list of variable names

modx.values

Values of moderator variable

mod2.values

Values of the second moderator variable

rangemode

Integer. 1 or 2.

maxylev

maximum unique length of variable to be treated as a categorical variable

digits

integer indicating the number of decimal places

Examples

fit=lm(govact~negemot*sex+negemot*age+posemot+ideology,data=glbwarm)
modSummary3(fit,mod2.values=c(30,50,70))
fit1=lm(govact~negemot*sex*age+posemot+ideology,data=glbwarm)
modSummary3(fit1,rangemode=1)
fit=lm(mpg~hp*wt,data=mtcars)
modSummary3(fit)

cardiomoon/processR documentation built on April 20, 2023, 3:38 a.m.