Description Usage Arguments Value Examples
This function shifts elemnts in a vector or a mtrix by a given lag. For example: mlag(x,1) - use yesterday's values and mlag(x,-1) - use tomorrow's values
1 | mlag(m, nlag = 1)
|
nlag |
number of lags, defaults to 1 |
x |
vector / matrix |
modified object
1 2 3 4 | ## Not run:
mlag(1:10)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.