Dear Statalist users,
I have monthly time series data on flight_delays per air_carrier. For each air_carrier (uniquely identified by date and carrier identifier), I want to compute the rolling sum of delays across the past 5 months (from t=0 until t=-5).
I was looking into tsegen but did not figure out how to solve the issue that tsegen does not allow for bysort.
It would be really kind if someone could help me with this, I have been trying to find a solution for this all morning.
Thanks
Christian
Related Posts with Computing rolling lagged sums with bysort
Convert Scientific Notations (e-07) into Decimal NotationHi All, I have various observations in my dataset like- 1.40e+09, 1.57e-07. How to convert these s…
Graphic with graphs for sub catvars and overall graphHello, I want to create a graphic with multiple graphs for each sub catvar and also a graph that is…
Why some global parameter is in { } while the others are not?Dear all, I'm helping my prof modify past code to adjust to the new dataset. It is my first time us…
Decomposing Wagstaff Concentration IndexDear All, I'm using Stata 16 and I'm trying to decompose my concentration index using the following…
Deleting entire Firm based on condition from panel data setHello Stata community, I have a panel dataset consisting of many firms over 20 years. Firms are iden…
Subscribe to:
Post Comments (Atom)
0 Response to Computing rolling lagged sums with bysort
Post a Comment