Announcement

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

  • Multinomial probit (mprobit): Syntax for specifying constraints

    Colleagues: The model being estimated is
    Code:
    mprobit y i.(x1 x2 x3 x4 x5)
    LHS variable y has 5 distinct categories and is coded {0,1,2,3,4}. Each x-variable is binary.

    I would like to estimate a constrained version of the model where the all coefficients corresponding to outcome categories 1, 2, and 3 are constrained to be equal. The first such constraint might be specified as
    Code:
    constraint 1 [1]_cons=[2]_cons
    etc. etc.

    Is it the case that each constraint for each pair of parameters must be defined in separate constraint commands, or are there any wildcard (or other shortcuts) that would permit all parameters (_cons, x1, ..., x5) for one outcome to be constrained equal to those for another outcome?

    Thanks very much in advance for any suggestions.

  • #2
    Maybe the following helps.

    Code:
    webuse sysdsn1
    constraint 1  [Prepaid=Uninsure] :age :male :nonwhite :2.site :3.site :_cons
    mprobit insure age male nonwhite i.site, constraints(1)

    Result:

    Code:
    . constraint 1  [Prepaid=Uninsure] :age :male :nonwhite :2.site :3.site :_cons
    
    . mprobit insure age male nonwhite i.site, constraints(1)
    
    Iteration 0:   log likelihood = -652.53577  
    Iteration 1:   log likelihood = -635.40528  
    Iteration 2:   log likelihood = -635.39863  
    Iteration 3:   log likelihood = -635.39863  
    
    Multinomial probit regression                   Number of obs     =        615
                                                    Wald chi2(5)      =      25.98
    Log likelihood = -635.39863                     Prob > chi2       =     0.0001
    
     ( 1)  [Prepaid]age - [Uninsure]age = 0
     ( 2)  [Prepaid]male - [Uninsure]male = 0
     ( 3)  [Prepaid]nonwhite - [Uninsure]nonwhite = 0
     ( 4)  [Prepaid]2.site - [Uninsure]2.site = 0
     ( 5)  [Prepaid]3.site - [Uninsure]3.site = 0
     ( 6)  [Prepaid]_cons - [Uninsure]_cons = 0
    ------------------------------------------------------------------------------
          insure |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    Indemnity    |  (base outcome)
    -------------+----------------------------------------------------------------
    Prepaid      |
             age |  -.0090318   .0047737    -1.89   0.058     -.018388    .0003245
            male |   .4383369   .1558006     2.81   0.005     .1329734    .7437004
        nonwhite |    .680846    .179048     3.80   0.000     .3299184    1.031774
                 |
            site |
              2  |  -.0278458   .1630128    -0.17   0.864     -.347345    .2916534
              3  |  -.4080612   .1710502    -2.39   0.017    -.7433134    -.072809
                 |
           _cons |  -.1806967   .2525669    -0.72   0.474    -.6757187    .3143252
    -------------+----------------------------------------------------------------
    Uninsure     |
             age |  -.0090318   .0047737    -1.89   0.058     -.018388    .0003245
            male |   .4383369   .1558006     2.81   0.005     .1329734    .7437004
        nonwhite |    .680846    .179048     3.80   0.000     .3299184    1.031774
                 |
            site |
              2  |  -.0278458   .1630128    -0.17   0.864     -.347345    .2916534
              3  |  -.4080612   .1710502    -2.39   0.017    -.7433134    -.072809
                 |
           _cons |  -.1806967   .2525669    -0.72   0.474    -.6757187    .3143252
    ------------------------------------------------------------------------------

    Comment


    • #3
      Thanks very much, Andrew. I was not aware of that syntax, but it is exactly what I need.

      I suppose it was too much to hope that there would be some sort of wildcard. A middle ground I'll consider is to use a local that can be invoked repeatedly, e.g.
      Code:
      webuse sysdsn1
      local rhs "age male nonwhite 2.site 3.site"
      constraint 2 [Prepaid=Uninsure] :`rhs' :_cons
      mprobit insure age male nonwhite i.site, constraints(2)
      Results
      Code:
      Multinomial probit regression                   Number of obs     =        615
                                                      Wald chi2(5)      =      25.98
      Log likelihood = -635.39863                     Prob > chi2       =     0.0001
      
       ( 1)  [Prepaid]age - [Uninsure]age = 0
       ( 2)  [Prepaid]male - [Uninsure]male = 0
       ( 3)  [Prepaid]nonwhite - [Uninsure]nonwhite = 0
       ( 4)  [Prepaid]2.site - [Uninsure]2.site = 0
       ( 5)  [Prepaid]3.site - [Uninsure]3.site = 0
       ( 6)  [Prepaid]_cons - [Uninsure]_cons = 0
      ------------------------------------------------------------------------------
            insure |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
      -------------+----------------------------------------------------------------
      Indemnity    |  (base outcome)
      -------------+----------------------------------------------------------------
      Prepaid      |
               age |    -0.0090     0.0048    -1.89   0.058      -0.0184      0.0003
              male |     0.4383     0.1558     2.81   0.005       0.1330      0.7437
          nonwhite |     0.6808     0.1790     3.80   0.000       0.3299      1.0318
                   |
              site |
                2  |    -0.0278     0.1630    -0.17   0.864      -0.3473      0.2917
                3  |    -0.4081     0.1711    -2.39   0.017      -0.7433     -0.0728
                   |
             _cons |    -0.1807     0.2526    -0.72   0.474      -0.6757      0.3143
      -------------+----------------------------------------------------------------
      Uninsure     |
               age |    -0.0090     0.0048    -1.89   0.058      -0.0184      0.0003
              male |     0.4383     0.1558     2.81   0.005       0.1330      0.7437
          nonwhite |     0.6808     0.1790     3.80   0.000       0.3299      1.0318
                   |
              site |
                2  |    -0.0278     0.1630    -0.17   0.864      -0.3473      0.2917
                3  |    -0.4081     0.1711    -2.39   0.017      -0.7433     -0.0728
                   |
             _cons |    -0.1807     0.2526    -0.72   0.474      -0.6757      0.3143
      ------------------------------------------------------------------------------
      Thanks again for your help and for the tutorial.

      Comment

      Working...
      X