Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

treatModerator

Treat moderator name with mean value


Description

Treat moderator name with mean value

Usage

treatModerator(
  ind,
  moderatorNames,
  data = NULL,
  rangemode = 1,
  probs = c(0.16, 0.5, 0.84)
)

Arguments

ind

An equation

moderatorNames

character vectors

data

A data.frame

rangemode

range mode

probs

numeric vector of probabilities with values in [0,1]

Examples

ind="(a1+a4*sex+a5*age)*(b1)"
moderatorNames=c("age","sex")
treatModerator(ind,moderatorNames)
ind="c1+c3*hp"
moderatorNames="hp"
treatModerator(ind,moderatorNames)

processR

Implementation of the 'PROCESS' Macro

v0.2.6
GPL-2
Authors
Keon-Woong Moon [aut, cre], Sokyoung Hong [ctb]
Initial release
2021-1-5

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.