Stochastic linear trend code
-
Raymond Shu
- Posts: 3
- Joined: Tue Feb 21, 2017 12:43 pm
Stochastic linear trend code
Greetings to all,
I'm wondering is there a code similar to linreg could extract a stochastic linear trend from a longitudinal dataset (for example unemployment rate).
Many thanks
I'm wondering is there a code similar to linreg could extract a stochastic linear trend from a longitudinal dataset (for example unemployment rate).
Many thanks
Re: Stochastic linear trend code
Do you have a reference? I have no idea what that would mean. You're looking for a common trend in several different unemployment rate series?
-
Raymond Shu
- Posts: 3
- Joined: Tue Feb 21, 2017 12:43 pm
Re: Stochastic linear trend code
Hi, thank you for asking. This is about my teamwork at school and we are asked to analyse monthly time series. So we take the US monthly unemployment rate from 1997 jan to 2017 jan. We are asked to suppose there exist a deterministic trend and a stochastic trend and to transform the data to show the trends. For the deterministic trend, we simply used "linreg", while for stochastic trend, we have no idea if there is a specific code for transforming the data.
Re: Stochastic linear trend code
FYI, longitudinal data means panel data, not time series data (hence my confusion about the question). It sounds like you want the Hodrick-Prescott trend. That's the most common method to estimate a variable trend in economics. The Spencer and Henderson trends are used in other areas (Henderson is used heavily in seasonal adjustment). Those last two are also mainly for extracting a trend+cycle, rather than just trend.
-
Raymond Shu
- Posts: 3
- Joined: Tue Feb 21, 2017 12:43 pm
Re: Stochastic linear trend code
Actually, we have not gone that deep, but finally we found that the answer was not as complicates as we had thought. Thanks a lot for your answer. 