Dear Statalisters,
I'm having trouble using tsfilter.
I have a dataset such as the one attached. Year and fid are the time and ID variable, respectively, and there are a few numerical variables (3 in the small dataset here below, called var1-var3)
Var1-var3 have missing values due to entry and exit. So for example in var1 the first panel might span years 1990-1999, the second panel 1998-2005, the third panel 1992-2002 and so on.
I'm trying to run a simple code such as
and I get error messages, different ones depending on the options I specify.
What should I do?
Thanks!
I'm having trouble using tsfilter.
I have a dataset such as the one attached. Year and fid are the time and ID variable, respectively, and there are a few numerical variables (3 in the small dataset here below, called var1-var3)
Var1-var3 have missing values due to entry and exit. So for example in var1 the first panel might span years 1990-1999, the second panel 1998-2005, the third panel 1992-2002 and so on.
I'm trying to run a simple code such as
Code:
tsfilter hp var1_hp var2_hp var3_hp = var1 var2 var3, smooth(100) trend(var1_tr var2_tr var3_tr)
What should I do?
Thanks!
Comment