lag.pserie {plm} | R Documentation |
Computes the lag of variables that have a time and an individual dimension.
lag.pserie(x,k=1,...)
x |
a vector of class pserie , |
k |
the order of the lag to be computed, |
... |
further arguments. |
a vector of the same length as x
containing the
lag values. NA
values are inserted at the correct positions.
Yves Croissant
library(Ecdat) data(Produc) Produc=pdata.frame(Produc,"state","year") lag(Produc$pc) lag(Produc$pc,k=2)