
plot_diff(model, view, comp, cond = NULL, plotCI = TRUE, f = 1.96,
eegAxis = FALSE, col = "black", shade = TRUE, n.grid = 100,
add = FALSE, print.summary = getOption("itsadug_print"), plot = TRUE,
rm.ranef = NULL, main = NULL, ylab = NULL, xlab = NULL, ylim = NULL,
hide.label = FALSE, ...)
add=TRUE
,
the function will generate an error.infoMessages
).est
) and the standard error over the estimate (se.est
) and
the x-values (x
). Default is est
) and the standard error
over the estimate (se
) and the x-values (x
) is returned.fvisgam
,
vis.gam2
; plotDiff2D
,
plot_diff2
; plot_parametric
;
plot_smooth
; plot_topo
;
pvis.gam
, pvisgam
data(simdat)
m1 <- bam(Y ~ Group + te(Time, Trial, by=Group),
data=simdat)
plot_diff(m1, view='Time', comp=list(Group=c("Children", "Adults")))
# Reversed y-axis (for EEG data):
plot_diff(m1, view='Time', comp=list(Group=c("Children", "Adults")),
eegAxis=TRUE)
# retrieving plot values...
out <- plot_diff(m1, view='Time', comp=list(Group=c("Children", "Adults")),
plot=FALSE)
#... which might be used for indicating differences:
x <- find_difference(out$est, out$se, f=1.96, xVals=out$xVals)
# add lines:
arrows(x0=x$start, x1=x$end, y0=0, y1=0,code=3, length=.1, col='red')
Run the code above in your browser using DataLab