Announcement

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

  • #16
    Thanks Richard,

    I have the same versions of -brant- and -oparallel-:

    Code:
    . which brant
    j:\ado\plus\b\brant.ado
    *! version 4.0.0 2017-08-23 | long freese | stata 15 parameter naming fix
    
    . which oparallel
    j:\ado\plus\o\oparallel.ado
    *! version 1.0.8 21Okt2013 MLB
    *!
    *! subroutines for the Wolfe-Gould test based on:
    *!   -omodel- version 1.0.1  26Sep1997  Rory Wolfe and Bill Gould  STB-42 sg76
    *!
    *! subroutines for the Brant test based on:
    *!   -brant- version 1.6.0 3/29/01 by J. Scott Long and Jeremy Freese
    So, I have no clue why I get this mysterious error after running -brant-.
    Perhaps it has something to do with the nature of my variables? They are all categorical with the coding deteriorate (-1), unchanged (0) and increase (1)?

    Thanks again!

    Carsten

    Comment


    • #17
      Ah. The manual says

      "The categorical variable to which factor-variable operators are applied must contain nonnegative integers." So try adding 1 to each categorical variable and see if that works.
      -------------------------------------------
      Richard Williams, Notre Dame Dept of Sociology
      Stata Version: 17.0 MP (2 processor)

      EMAIL: [email protected]
      WWW: https://www3.nd.edu/~rwilliam

      Comment


      • #18
        Also, I just noticed that you are not using factor variable notation in your ologit command, so every var is being treated as continuous. Is that what you want?

        Code:
        ologit  generalecon salesprofit credithis capital bankcred
        Also make sure that Stat itself is up to date.
        -------------------------------------------
        Richard Williams, Notre Dame Dept of Sociology
        Stata Version: 17.0 MP (2 processor)

        EMAIL: [email protected]
        WWW: https://www3.nd.edu/~rwilliam

        Comment


        • #19
          OK, I think brant gets crabby when the DV has negative values. Add one to your DV and I think it will works, Example:

          Code:
          . webuse nhanes2f, clear
          
          . quietly ologit health age height weight
          
          . brant, detail
          
          Estimated coefficients from binary logits
          
          ----------------------------------------------------------
              Variable |  y_gt_1     y_gt_2     y_gt_3     y_gt_4   
          -------------+--------------------------------------------
                   age |   -0.056     -0.048     -0.036     -0.030  
                       |   -18.02     -28.31     -28.36     -20.33  
                height |    0.003      0.020      0.028      0.031  
                       |     0.57       6.81      10.81      10.28  
                weight |   -0.007     -0.012     -0.012     -0.013  
                       |    -2.36      -6.47      -7.29      -6.72  
                 _cons |    5.629      1.099     -2.200     -4.168  
                       |     7.30       2.31      -5.46      -8.86  
          ----------------------------------------------------------
                                                         legend: b/t
          
          Brant test of parallel regression assumption
          
                        |       chi2     p>chi2      df
           -------------+------------------------------
                    All |     112.78      0.000       9
           -------------+------------------------------
                    age |      93.46      0.000       3
                 height |      30.14      0.000       3
                 weight |       4.11      0.250       3
          
          A significant test statistic provides evidence that the parallel
          regression assumption has been violated.
          
          . gen xhealth = health - 3
          (2 missing values generated)
          
          . quietly ologit xhealth age height weight
          
          . brant, detail
          - invalid name
          2 invalid name
          r(7);
          
          .
          -------------------------------------------
          Richard Williams, Notre Dame Dept of Sociology
          Stata Version: 17.0 MP (2 processor)

          EMAIL: [email protected]
          WWW: https://www3.nd.edu/~rwilliam

          Comment


          • #20
            Dear Richard,

            Thank you very much for your extensive help on this! I really appreciate it! I think what you and your fellow 'tenured members' here at Statalist are doing every day is of great value for many researchers!

            It all works fine now.

            Also, I just noticed that you are not using factor variable notation in your ologit command, so every var is being treated as continuous. Is that what you want?
            I know that it is not optimal to treat them as continuous. But I think the trade-off here is between optimal accuracy of the results and a straightforward interpretation of the results (and of course parsimony). Although the -lrtest- says that categorical variables have a better fit and the -brant- test now says that all of the ordinal independent variables are violating the parallel regression assumption, I am a bit concerned that I am overparameterizing the model, since I have so many of the ordinal independent variables.

            Maybe you also have a general comment on that.

            But anyway, thanks again for your help!

            Best,

            Carsten

            Comment


            • #21
              A discussion of ordinal independent variables can be found at

              https://www3.nd.edu/~rwilliam/stats3...ndependent.pdf
              -------------------------------------------
              Richard Williams, Notre Dame Dept of Sociology
              Stata Version: 17.0 MP (2 processor)

              EMAIL: [email protected]
              WWW: https://www3.nd.edu/~rwilliam

              Comment


              • #22
                Dear professor Richard Williams

                I also have a problem regarding brant, detail after ologit.

                . brant, detail
                r(2000);

                please any advice?
                best regards
                karzanEnable GingerCannot connect to Ginger Check your internet connection
                or reload the browserDisable in this text fieldRephraseRephrase current sentence6Log in to edit with GingerĂ—

                Comment

                Working...
                X