Announcement

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

  • rolling window: updated deciles after each iteration

    Hello,

    I have been conducting some analysis on persistency in fund managers' skill in creating value for their investors.

    I have sorted all funds based on skill ratio each time, t, as variable decile.
    To analyze the differences between the performance of different deciles, I have used the rangestat command in a rolling window mean estimation. Since I need to consider each decile at each time, I'm not sure if stata is doing it correctly.

    I'm supposed to use a measurement horizon of 3y-10y and estimate the skill for each decile. The deciles are supposed to "update" after each iteration of the rolling window estimation.

    The simplest way of putting it is that stata measures mean skill for all 10 deciles, that cathegorize the different funds, in the interval 1-36 first. Then it does the same but with different funds behind the decile cathegorization. In this way, I can check if there is persistency in skill.

    Below is my code and my problem lies on the "by(decile)" part, where I dont seem to find a way to tell stata that each iteration is supposed to consider new funds behind the deciles (different from the previous iteration).

    The deciles are correct as they are defined for each date, meaning each fund is put in 1 of 10 deciles for each date.

    Code:
    by fund: gen skillratio = mskill / varskill
    bys date: astile decile = skillratio, nq(10) // sort all funds based on skillratio each time, t
    rangestat (mean) skill, by(decile) interval(date 1 36) // m=36
    rangestat (mean) skill, by(decile) interval(date 1 48) // m=48
    rangestat (mean) skill, by(decile) interval(date 1 60) // m=60
    rangestat (mean) skill, by(decile) interval(date 1 72) // m=72
    rangestat (mean) skill, by(decile) interval(date 1 84) // m=84
    rangestat (mean) skill, by(decile) interval(date 1 96) // m=96
    rangestat (mean) skill, by(decile) interval(date 1 108) // m=108
    rangestat (mean) skill, by(decile) interval(date 1 120) // m=120

    When plotting the graph i get 10 lines that are pretty identical (though not fully identical) which does not coincide with the paper that I'm working with since it exhibits much more variation in the graphs.
    Therefore, I assume that what I'm doing with the "by(decile)" part must be wrong since I would expect some more variation between the plotted graphs.

    I have tried doing by(deciles date), however its flawed as it does not distinguish between the measurement horizons, m, and I only get the same graph across the different measurement horizons.

    I have been looking around and not found anything on this problem so any help is greatly appreciated.

    Beforehand, thank you for your insights!

  • #2
    rangestat is from SSC. I speak on its behalf.

    astile is also from SSC. I didn't write it and don't use it but what it does is (I guess) not the main issue here.

    In your calculation decile is a variable with (I guess) codes 1 to 10 for decile bins. (Historically deciles were particular quantiles but you seem to be following a common practice of extending the term to the bins they delimit.)

    The rangestat calls you wrote will do nothing to adjust decile bins. decile will remain exactly as determined by astile. But you did calculate decile bins separately by date, so I don't understand what else you're missing.

    Comment


    • #3
      That is what I have been thinking too, perhaps there is nothing wrong with the method but rather something with my sample.
      Regardless, thank you Nick

      Comment


      • #4
        I don't have experience with your kind of data. But if the code is sound, a positive diagnosis is that the results are surprising to you rather than incorrect.

        Or perhaps the idea that the decile bins should update is the source of difficulty. If the question were say skill in sport then even the best players or teams can plunge daily in rankings whenever they lose -- if rankings are computed daily.

        Comment


        • #5
          Indeed. I do get the desired result in which the skillratio (which is what the deciles are based upon) reflect the performance of funds. That is, P10 is better performing than P1.
          The problem for me is that the curve I get when I plot all deciles and their average performance is surprisingly smooth (compared to the paper im working with which is more jagged).

          Another concern I have is that I use multiple rolling window periods and they all yield very similar results, which seems to good to be true as the paper clearly has some differences when using different measurement horizons.
          The key takeaway, that fund performance is persistent is detected in my data though it seems to "perfect" compared to the paper.

          That is where my problem lies. Based on my code, do you see possible reasons for why this is?

          Code:
          bys date: astile decile = skillratio, nq(10) // sort all funds based on skillratio each time, t
          rangestat (mean) skill, by(decile) interval(date 1 36) // m=36
          rangestat (mean) skill, by(decile) interval(date 1 48) // m=48
          rangestat (mean) skill, by(decile) interval(date 1 60) // m=60
          rangestat (mean) skill, by(decile) interval(date 1 72) // m=72
          rangestat (mean) skill, by(decile) interval(date 1 84) // m=84
          rangestat (mean) skill, by(decile) interval(date 1 96) // m=96
          rangestat (mean) skill, by(decile) interval(date 1 108) // m=108
          rangestat (mean) skill, by(decile) interval(date 1 120) // m=120

          rename skill_mean years3 rename skill_mean years4 rename skill_mean years5 rename skill_mean years6
          rename skill_mean years7 rename skill_mean years8 rename skill_mean years9 rename skill_mean years10

          levelsof decile, local(deciles)
          foreach var of varlist years3-years10 {
          forvalues i = 1/10 {
          collapse years3 years4 years5 years6 years7 years8 years9 years10, by(decile)
          }
          }

          Comment


          • #6
            Another thing I noticed is that for each decile, the different measurement horizons seem to converge to (almost) the same mean value, which is why the problem occurs.
            Is it reasonable that they will converge? It certainly does not converge to the same degree for the paper im working with.

            Comment


            • #7
              As said, I don't have experience with your kind of data. You're asking for an explanation of the difference in results between your data (which we can't see) and those in an unspecified paper (whose data we can't see either). Sorry, but I can't help. Why not ask the authors of the paper in question for a copy of their data and their code?

              Comment


              • #8
                No problem. I highly doubt the authors of this paper will respond to my inquires, however thank you for your time

                Comment

                Working...
                X