| diff_cpp | R Documentation | 
Returns the ith difference of a time series of rth lag.
diff_cpp(x, lag, differences)
| x | A  | 
| lag | A  | 
| differences | A  | 
A vector containing the differenced time series.
JJB
x = rnorm(10000, 0, 1)
diff_cpp(x,1,1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.