[R] diff() for panel data

Gabriel Paul Mihalache mihalache at gmail.com
Sun Sep 21 02:01:07 CEST 2008


Hello, everyone!
I'd like to find out how I can do first log differences in a panel?
(The Penn World Table data that's available in the PWT package)
The regular diff() function ignores the country/index/"panel unit",
with depressing results.

A second request, how can I best "filter" the data (e.g. generate a
data frame with the data for a single country or a single year)?

Thank you!
Gabriel



More information about the R-help mailing list