Announcement

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

  • cmp multivariate probit

    Hi,

    I am running a multivariate probit model using the cmp function on 4 binary dependent variables.Yesterday I ran the model several times and it worked just fine. Today, when I try to run it, it returns the error message: initial vector: matrix must be dimension 109

    My code is thus:

    cmp setup
    cmp (DOWNLOAD = MALE AGE24 AGE39 AGE59 EDUCATION1 EDUCATION2 INCOME1 INCOME2 INCOME3 URBAN RURAL SOCIALMEDIA RECOM_FRIENDS RECOM_INTERNET RADIO TV MUSICTASTE1 MUSICTASTE2 MUSICTASTE3 MUSICTASTE4 MUSICGROUP PAIDSTREAMING FREESTREAMING VIDEO NEWSONLINE)(PIRACY = MALE AGE24 AGE39 AGE59 EDUCATION1 EDUCATION2 INCOME1 INCOME2 INCOME3 URBAN RURAL SOCIALMEDIA RECOM_FRIENDS RECOM_INTERNET RADIO TV MUSICTASTE1 MUSICTASTE2 MUSICTASTE3 MUSICTASTE4 MUSICGROUP PAIDSTREAMING FREESTREAMING VIDEO NEWSONLINE)(CD = MALE AGE24 AGE39 AGE59 EDUCATION1 EDUCATION2 INCOME1 INCOME2 INCOME3 URBAN RURAL SOCIALMEDIA RECOM_FRIENDS RECOM_INTERNET RADIO TV MUSICTASTE1 MUSICTASTE2 MUSICTASTE3 MUSICTASTE4 MUSICGROUP PAIDSTREAMING FREESTREAMING VIDEO NEWSONLINE)(MERCHETC = MALE AGE24 AGE39 AGE59 EDUCATION1 EDUCATION2 INCOME1 INCOME2 INCOME3 URBAN RURAL SOCIALMEDIA RECOM_FRIENDS RECOM_INTERNET RADIO TV MUSICTASTE1 MUSICTASTE2 MUSICTASTE3 MUSICTASTE4 MUSICGROUP PAIDSTREAMING FREESTREAMING VIDEO NEWSONLINE), indicators($cmp_probit $cmp_probit $cmp_probit $cmp_probit) robust difficult
    estimates table, star(.1 .05 .01)


    When I exclude the difficult and robust options, it tells me "too few variables specified" but I cannot work out why. Please advise,

    Many thanks,

    Jake

  • #2
    If you send me exact data and code to reproduce the problem, I can look at it. It's always possible there's a bug in cmp, though in this case, given the changing error messages, I'd guess it's more likely there's a bug in your do file.

    Comment


    • #3
      Hi Mr Roodman,

      Sorry for the late response, I was away over the weekend. Thank you for offering your help. I am using university library computers. It's strange since when I run it on one of the computers, it works, and when I run it on another computer, it doesn't. I have tried other unrelated, more simple regressions on both computers and they give the same coefficients and standard errors, suggesting there is not anything fundamentally wrong with either of them.

      Another issue I have encountered (when the multivariate regression does work) is thus: when I include all 4 dependent variables as described above, the multivariate output yields coefficients and standard errors for all explanatory variables. However, when I remove MERCHETC (ie. I only run the multivariate model with the dependent variables CD, DOWNLOAD and PIRACY), no standard errors are produced for PIRACY and its coefficients for AGE variables are huge.

      I have attached my data and do files for the multivariate and individual probits. I have also attached word documents with the output I am getting for comparison. Many thanks for your help,

      Jake


      Attached Files

      Comment


      • #4
        In the multivariate regression with all 4 dependent variables, I was also slightly confused about the high coefficients and high significance for the AGE variables in PIRACY regression (eg. 4.486724; 4.313742; 3.9905). Do these look suspect or fine?

        Thanks again

        Comment


        • #5
          Hi Jake,
          The code you provided worked fine for me in both Stata 11.2 and 16.1, as in the output you provided. If you are able to reproduce the error you described, you could do it after "set trace on" and send me the results of that.

          As for the missing standard errors, this is a general question about Stata's ml command. That happens when the Hessian of the likelihood at the chosen solution is not of full rank, and so cannot be perfectly inverted to estimate standard errors. You might try dropping regressors or increasing the tolerances required for declaring convergence or switching to vce(opg).
          --David

          Comment


          • #6
            Hi Mr Roodman,

            Many thanks. I will see what happens with increased tolerance etc. Can you offer a basic explanation as to why Stata would manage to produce standard errors when MERCHETC is included in the multivariate model, but not when it is excluded from it? I find this quite confusing. The MERCHETC regression is not significant overall on its own, so I had considered removing it from the multivariate model (as that seemed logical to do although I am not sure whether individual significance of an equation is a key determinant in its inclusion in a multivariate model?) but then the multivariate model did not work without it, so I wasn't sure what to do. It's also problematic removing important rgeressors from the PIRACY equation. Is it ok to leave MERCHETC equation in if I can't get the model to converge without it?

            Many thanks,

            Jake

            Comment


            • #7
              I have the model excluding MERCHETC and have managed to get it to converge with only the three dependent variables included, using the "nonrtolerance" option. The direction and significance of explanatory variables are the same as in the 4 dependent variable model, and the coefficients are similar, which is encouraging.

              The only problem I'm having is that when I only run the three dependent variables, it does not give me standard errors or p values for the constant term in PIRACY. Can you think why this is happening?

              Many thanks

              Comment

              Working...
              X