Learn R Programming

languageR (version 1.2)

preparePredictor.fnc: determine X and Y values for a given (sub)plot

Description

this function figures out the X and Y values for a given (sub)plot, including upper and lower 95% HPD intervals

Usage

preparePredictor.fnc(pred, model, m, ylabel, fun, val, xlabel, mcmc, ranefs, ...)

Arguments

pred
character string denoting predictor to be plotted on horizontal axis
model
model fit by lmer
m
matrix as produced by makeDefaultMatrix.fnc
ylabel
label for vertical axis (if other than name of dependent variable
fun
character string denoting transformation function for dependent variable, currently only '"plogis"' or '"exp"'
val
value of interacting variable
xlabel
label for horizontal axis
mcmc
MCMC matrix as produced by mcmcsamp or pvals.fnc()$mcmc
ranefs
a three-element list Group, Level, Predictor, specifying a random-effect Group (e.g. Subject), a level (e.g., S10) and a value (e.g., LogFrequency) for which partial effects have to be calibrated; implem
...
further graphical parameters, currently not implemented

Value

  • A data frame with values to be plotted, with columns
  • Xvalues of predictor
  • Yfitted values
  • Typelogical for whether predictor is factor
  • Interactionlogical for whether predictor is interacting predictor
  • Levelsfor factors, the factor level names (only present for factors)

See Also

See Also as plotLMER.fnc

Examples

Run this code
Not intended for independent use.

Run the code above in your browser using DataLab