I have a data set of American companies over the period 1985-2015 with circa 300k observations of leverage-ratios. So every company has 30 observations.
For a figure I have to construct the average leverage ratios of four portfolios in 'event time' . So what I want to do is the following: each year, I sort firms into quartiles (creating four portfolios) according to their leverage-ratio. The portfolio is denoted event year 0 and I want to compute the average leverage for each portfolio in each of the following 20 years. I want to do this by creating portfolios for year=1985 and so on. How can I follow the different portfolios over the years and compute their average leverage-ratios?
To illustrate, from one year I can derive the 4 quartiles and their average leverage. The next step would be to isolate each quartile (each group of firms) and follow particular group and see how their average leverage develops over time. Can anyone help me with isolating a quartile and filtering the data in a way that you can observe the leverage of these firms in t+1, t+2, etc.
Please let me know if my issue is not clear.
Thanks in advance,
Koen van Hanegem
Related Posts with Following different portfolios over time
Interpreting margins results for a mlogit regression with variable of interest in logHello everyone This was a long title, but it summarizes well my issue. I ran a mlogit regression w…
Stata DateI have posted a dataex for my data which quotes dates in the form YYYY.MM: * Example generated by -d…
Two-Stage Least Squares with cross-section weights and adjusted-R2Hi! I am currently analysing daily yield spreads of the euro-area countries over a 10-year period. I…
reformat (destring) var questionHi Hi, I am relatively new to stata and want to reformat a variable. the var is named p3_start_TS, …
Summing or combining duplicate observationsHello all, I would like to ask how to combine/sum up data from duplicate observations. In the below…
Subscribe to:
Post Comments (Atom)
0 Response to Following different portfolios over time
Post a Comment