| nl_predict | R Documentation |
Creates a prediction data frame over a grid of the focal predictor x
(and optionally over time), holding control variables at typical
values. For mixed models, predictions default to population-level curves
(random effects set to zero).
v2 improvements:
CI for glmerMod: approximate confidence intervals are
computed via the parametric bootstrap or the delta method. Set
glmer_ci = "delta" (default, fast) or "boot" (more
accurate, slower).
Cluster-specific predictions: set re_form = NULL
to include random effects in the predictions.
nl_predict(
object,
x_seq = NULL,
time_levels = NULL,
controls_fixed = NULL,
se = TRUE,
level = 0.95,
re_form = NA,
glmer_ci = c("delta", "boot"),
n_boot = 500L,
...
)
object |
An |
x_seq |
Optional numeric vector of x values. If |
time_levels |
Optional vector of time levels. |
controls_fixed |
Optional named list of fixed control values. |
se |
Logical; include SEs and CIs. Default |
level |
Confidence level. Default |
re_form |
For mixed models: |
glmer_ci |
Method for glmerMod CIs: |
n_boot |
Number of bootstrap replicates when |
... |
Reserved for future use. |
A data frame with columns for the focal predictor, time (if any),
controls at fixed values, fit, se.fit, lwr,
and upr.
nl_fit, nl_plot,
nl_derivatives
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.