Usage
plot_diff2(model, view, comp, cond = NULL, plotCI = FALSE, f = 1.96,
color = "topo", nCol = 100, col = NULL, add.color.legend = TRUE,
n.grid = 30, nlevels = 10, zlim = NULL, main = NULL,
print.summary = TRUE)
Arguments
model
A GAMM model, resulting from the functions
gam
or bam
. view
Name of continuous predictors that should be plotted on the x-
and y-axes. Vector of two values.
comp
Named list with the grouping predictor (categorical variable)
and the 2 levels to calculate the difference for.
cond
Named list of the values to use for the other predictor terms
(not in view).
plotCI
Logical: whether or not to plot confidence intervals.
f
A number to scale the standard error. Defaults to 1.96, resulting
in 95% confidence intervals. For 99% confidence intervals use a value of
2.58.
nCol
Range of colors of background of contour plot.
add.color.legend
Logical: whether or not to add a color legend.
Default is TRUE. If FALSE (omitted), one could use the function
gradientLegend
to add a legend manually at any position. nlevels
Levels of contour lines.
zlim
A two item array giving the lower and upper limits for the z-
axis scale. NULL to choose automatically.
print.summary
Logical: whether or not to print a summary.