Plot residuals vs lagged residuals for time series data
rvlrplot [ , residualtype qualifier scatter_options plot(plot) ]
rvlrplot plots residuals from the last model versus lagged (i.e. lag 1) residuals. Data must have been tsset previously.
By default, residuals are whatever predict, res produces after a model. The plot is restricted to the estimation sample.
The correlation between residuals and lagged residuals is calculated quietly. This may be retrieved by return list and then (say) used in a second pass giving the correlation on the graph.
If the order of observations is meaningful, but data have not been tsset, this may be done by
gen t = _n tsset t
residualtype specifies a type of residual other than the default. The following types are currently supported: anscombe, deviance, likelihood, pearson, residuals, response, rstandard, rstudent, score, working.
qualifier specifies one of standardized, studentized, modified, adjusted.
scatter_options are options of twoway scatter.
plot(plot) provides a way to add other plots to the generated graph; see plot_option.
. tsset time . regress whatever time . rvlrplot
Nicholas J. Cox, University of Durham, U.K. firstname.lastname@example.org
On-line: help for predict, scatter, tsset, modeldiag