View source: R/plotScatterAcd.R
plotScatterAcd  R Documentation 
Function to help scatter plot different variables of a fitted ACD model and superimposes a smoothed conditional mean using ggplot2. Can be used to investigate the possible need for nonlinear models and issues with the diurnal adjustment.
plotScatterAcd(fitModel, x = "muHats", y = "residuals", xlag = 0, ylag = 0,
colour = NULL, xlim = NULL, ylim = NULL, alpha = 1/10,
smoothMethod = "auto")
fitModel 
a fitted model of class "acdFit" 
x 
the variable used on the xaxis. One of "muHats", "residuals", "durations", "adjDur", "dayTime", "time", or "index". 
y 
the variable used on the yaxis. One of "muHats", "residuals", "durations", "adjDur", "dayTime", "time", or "index". 
xlag 
number of lags used for the variable shown on the xaxis. 
ylag 
number of lags used for the variable shown on the yaxis. 
colour 
a possible third variable to be represented with a colour scale. One of "muHats", "residuals", "durations", "adjDur", "dayTime", or "time". 
xlim 
a vector of the limits of the xaxis to possibly zoom in on a certain region. 
ylim 
a vector of the limits of the yaxis to possibly zoom in on a certain region. 
alpha 

smoothMethod 
value passed as 
Markus Belfrage
## Not run:
# The mean residuals are too small for small values of the estimated conditional
# mean, suggesting a need for a different conditional mean model specification:
fitModel < acdFit(adjDurData)
plotScatterAcd(fitModel, x = "muHats", y = "residuals")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.