Announcement

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

  • Should I use "c." or "i." prefix or something else?

    Dear all,

    I have a panel dataset of rated firms and want to study the effect of busyness cycles on credit ratings. I want to use the "xtlogit" command to model ordered ratings as a function of some financial and market variables and a linear trend in addition to a busyness cycles variable. The indicator of busyness cycles is based on the GDP growth such that for the lower third of the yearly growth distribution, it is assigned -1, and for the middle third, it is 0, and for the upper third, it is +1. Now my question is to find the effect of the state of the cycle on ratings. Should I use the variable with the prefix "c."?

    I want to see how the state of the busyness cycle affects credit ratings. using the prefix "i."

    Thanks in advance.

  • #2
    Your business cycle variable (which I will name cycle) seems to be appropriately treated as a categorical variable rather than a continuous variable.

    As such, i.cycle would seem to be appropriate. This would include in the model three (virtual) indicator variables for the three levels of the business cycle, and would of course lead to one of those three being omitted from the model to avoid collinearity.

    However, the output of help factor variables tells us

    Categorical variables to which factor-variable operators are applied must contain nonnegative integers with values in the range 0 to 32,740, inclusive.
    So you will want to recode your business cycle variable to avoid the negative value. One way of doing this is to create a new variable with recoded values and value labels.
    Code:
    recode cycle (-1=1 "Low") (0=2 "Middle") (1=3 "High"), generate(bcycle)
    And then you can included i.bcycle in your model
    Code:
    regress ratings i.bcycle ...
    By default the lowest valued category - 1 in this case - will be omitted from the model, but you may prefer to omit the middle category.
    Code:
    regress ratings ib2.bcycle ...

    Comment


    • #3
      Ali:
      as an aside to William's helpful advice, why not using -xtologit- if your regressand is ordered?
      Kind regards,
      Carlo
      (Stata 19.0)

      Comment


      • #4
        Originally posted by William Lisowski View Post
        Your business cycle variable (which I will name cycle) seems to be appropriately treated as a categorical variable rather than a continuous variable.

        As such, i.cycle would seem to be appropriate. This would include in the model three (virtual) indicator variables for the three levels of the business cycle, and would of course lead to one of those three being omitted from the model to avoid collinearity.

        However, the output of help factor variables tells us



        So you will want to recode your business cycle variable to avoid the negative value. One way of doing this is to create a new variable with recoded values and value labels.
        Code:
        recode cycle (-1=1 "Low") (0=2 "Middle") (1=3 "High"), generate(bcycle)
        And then you can included i.bcycle in your model
        Code:
        regress ratings i.bcycle ...
        By default the lowest valued category - 1 in this case - will be omitted from the model, but you may prefer to omit the middle category.
        Code:
        regress ratings ib2.bcycle ...
        Thanks William! I appreciate it.

        Comment


        • #5
          Originally posted by Carlo Lazzaro View Post
          Ali:
          as an aside to William's helpful advice, why not using -xtologit- if your regressand is ordered?
          My ideal is to use "xtoprobit" but I'm using "xtologit" because it converges. The reason why I asked about xtlogit was to check some alternatives.
          Working with "xtoprobit" is difficult because it does not converge, and I don't know why. Tried some suggestions in the forum but it didn't work out for me.

          Comment


          • #6
            Ali:
            the usual fix is to start it all over again adding one predictor at a time and see when convergence problems start to creep up.
            Kind regards,
            Carlo
            (Stata 19.0)

            Comment

            Working...
            X