Hi all
I have Gross Domestic Product, gdp, data that are in vintages (i.e. the gdp variable is revised over time, so gdp65Q4 below is the gdp data revised at a vintage date of year 1965 quarter 4. Therefore for each column below we have gdp data for each quarter measured on a specific vintage date. The next column will show how the gdp for the same quarters have been revised in a subsequent vintage date and so on. To clarify more, the first cell 306.4 on the north west corner represents gdp in quarter 1 year 1947 but as revised in quarter 4 of year 1965, the next cell to the right 307.4 represents gdp in quarter 1 year 1947 again but as revised in quarter 1 year 1966....and so on)
What I want to do is to generate a variable that represents gdp vintage shock and measured as residual of a regression of gdp at a given vintage date on the same gdp at a previous vintage date.
I do not know how a loop can estimate that ?
Thank you
I have Gross Domestic Product, gdp, data that are in vintages (i.e. the gdp variable is revised over time, so gdp65Q4 below is the gdp data revised at a vintage date of year 1965 quarter 4. Therefore for each column below we have gdp data for each quarter measured on a specific vintage date. The next column will show how the gdp for the same quarters have been revised in a subsequent vintage date and so on. To clarify more, the first cell 306.4 on the north west corner represents gdp in quarter 1 year 1947 but as revised in quarter 4 of year 1965, the next cell to the right 307.4 represents gdp in quarter 1 year 1947 again but as revised in quarter 1 year 1966....and so on)
date | gdp65Q4 | gdp66Q1 | gdp66Q2 | gdp66Q3 |
1947:Q1 | 306.4 | 307.4 | 309.4 | 302.4 |
1947:Q2 | 309 | 301 | 302 | 309 |
1947:Q3 | 309.6 | 304.6 | 308.6 | 302.6 |
1947:Q4 | 314.5 | 315.5 | 314.5 | 310.5 |
1948:Q1 | 317.1 | 311.2 | 314.3 | 319.1 |
1948:Q2 | 322.9 | 325.7 | 333.9 | 322.9 |
I do not know how a loop can estimate that ?
Thank you
Comment