cookPasta {pastaPlot}R Documentation

Spaghetti-plot fixed and random effects of linear mixed models

Description

cookPasta() creates dataframes from fixed and random effects of 'lme4' or 'glmmTMB' models (e.g., for plotting)

Usage

cookPasta(
  model = NULL,
  predictor = NULL,
  nested.in = NULL,
  group = NULL,
  ci.int = FALSE,
  ci.lvl = ci.lvl
)

Arguments

model

lme4 or glmmTMB model object

predictor

(Character) Name of predictor (e.g., "time" or "math_score"), as it is present in the model

nested.in

(Character) Name of the variable your time points or subjects are nested in (e.g.,"school" or "id")

group

(Optional, character) The name of your grouping variable (e.g., "condition" or "gender")

ci.int

(Optional, boolean) Enable confidence (prediction) intervals, disabled by default

ci.lvl

(Optional, numeric) Set level of confidence (prediction) intervals (default: 0.95). Requires ci.int to be set to TRUE

Value

Returns a list of two dataframes, in which the first element is the fixed effects dataframe and the second element the random effects dataframe


[Package pastaPlot version 0.1.0 Index]