Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Sum of future annuities

    Hi everyone

    I am trying to calculate long run dividend growth rates using the following sum:
    Click image for larger version

Name:	Capture.PNG
Views:	1
Size:	5.2 KB
ID:	1448644

    where the infinity can be replaced by 100 periods. r-bar and g-bar are sample average return and dividend growth rate respectively. Normal g is dividend growth rate which is missing for some observations.

    I am using an unbalanced panel dataset with permno, the firm identifier, as panel variable and time(%tm) as time variable (delta = 1 month). Furthermore I used

    tsappend, add(100)

    to add 100 periods and replaced future missing values with the firm mean dividend growth rate in order to make sure that each firm observation has at least 100 periods of dividend growth rates.

    The sum should be calculated per firm and for each observation. I tried the following code but I came to realize that it did not exactly do what I wanted:

    Code:
    forvalues i = 1(1)100 {
        by permno: egen compound = total((1.0048875/1.0119962)^(`i')*cgrowth[_n+`i'+1])
        }
    I also tried -tsegen- to get the present value of future growth rates, however I could not combine it with the first term after the sigma (1+g-bar/1+r-bar)^i.

    Can anyone help me with this?

    Thanks in advance!
    Roger

  • #2
    You'll increase your chances of a useful answer by following the FAQ on asking questions – provide Stata code in code delimiters, readable Stata output, and sample data using dataex. Telling us something doesn't do what you want is not terribly informative.

    Assume you have r-bar, g-bar, and g as locals. Then,
    local runsum 0
    forvalues i= 1=1/100 {
    local runsum=`runsum' + ((1+`g-bar')/(1+`rbar')^`i'
    }
    local ag=((`rbar' -`gbar')/(1 + `rbar')) * `runsum' *`g'

    I haven't run this or debugged it, but it will give you the idea. Another option, involving more coding, is to write out the summation with the different exponents (Yes all 100 terms).



    Comment


    • #3
      Hi Phil,

      Thank you very much for your response and apologies that i did not follow the FAQ.

      I read the manual on macros and ran your code in the following form:


      Code:
      local gb = 0.0048875
      local rb = 0.0119962
      local runsum = 0
      local gro = cgrowth
      
      
      forvalues i=1(1)100{
      local runsum = `runsum' + ((1+`gb')/(1+`rb')^`i')*`gro'
      }
      local ag = ((`rb'-`gb')/(1+`rb'))*`runsum'
      gen ag= `ag'
      However this yields a single ag value for all my observations, whereas I want different ag values for all my different firm-months. How can I achieve this? Furthermore, should I include cgrowth, a variable that differs per firm-month as a local or just as a normal variable? And how do I let it loop through future values of cgrowth like in the formula?

      Thanks in advance!!


      Comment

      Working...
      X