Thanks to Kit Baum, a new version of tsegen (with Nick Cox) is now available on SSC.
tsegen is useful for computing descriptive statistics over a rolling window of time using egen row functions. By using a set of time-series variables, tsegen can compute the statistic directly and is orders of magnitude faster than other approaches that require looping over subsets of observations.
The new version is designed to overcome Stata's limit of 100 unique time-series operators in a command. We became aware of the limit in a recent post by Jean-Marie Meier. See the following post for an example of a rolling average over a window of 1460 days (4 years).
To update to the new version, type in Stata's command window
or
tsegen is useful for computing descriptive statistics over a rolling window of time using egen row functions. By using a set of time-series variables, tsegen can compute the statistic directly and is orders of magnitude faster than other approaches that require looping over subsets of observations.
The new version is designed to overcome Stata's limit of 100 unique time-series operators in a command. We became aware of the limit in a recent post by Jean-Marie Meier. See the following post for an example of a rolling average over a window of 1460 days (4 years).
To update to the new version, type in Stata's command window
Code:
adoupdate
Code:
ssc install tsegen, replace
Comment