Announcement

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

  • error with ivregress and ivreg2

    Hi everyone,

    First-time user here! Currently an undergrad student and I desperately need help for the ivregress and ivreg2. I'm currently estimating a simultaneous equation system with 2SLS and GMM and would need help in inputing the right commands in stata. Here's a brief description of my variables

    Endogenous: GDP, KAP, EM, HK, OPEN, FDI, SAV, WEALTH
    Exogenous: interest, tax, inflat, gtran, gee, rmb, wage, pc
    Instruments: lagged endogenous variables + lagged and current exogenous variables

    System of equations
    1. GDP KAP EM HK FDI SAV gtran
    2. KAP GDP OPEN FDI SAV interest tax
    3. EM GDP HK OPEN FDI interest inflat
    4. HK GDP FDI SAV interest gtran gee
    5. OPEN GDP KAP EM HK intrest rmb inflat pc
    6. FDI GDP HK OPEN rmb wage tax pc
    7. SAV GDP EM WEALTH interest tax pc
    8. WEALTH GDP OPEN SAV interest tax

    I tried it with ivreg2, seem to keep getting an error

    . ivreg2 d1lgdp (d1lkap d1lem d1lhk d1lfdi d1lsav = d1lgtran d1lkap_1 d1lem_1 d1lhk_1 d1lfdi_1 d1lsav_1 d1lgtran_1
    > ), first
    struct ms_vcvorthog undefined
    (817 lines skipped)
    (error occurred while loading ivreg2.ado)
    r(3000);

    Here's what came out when I used ivregress,

    . ivregress d1lgdp (d1lkap d1lem d1lhk d1lfdi d1lsav = d1interest d1ltax d1inflat d1lgtran d1lgee d1rmb d1wage d1lpc
    > d1interest_1 d1ltax_1 d1inflat_1 d1lgtran_1 d1lgee_1 d1rmb_1 d1wage_1 d1lpc_1 d1lgdp_1 d1lkap_1 d1lem_1 d1lhk_1 d1
    > lopen_1 d1lfdi_1 d1lsav_1 d1lwealth_1), first
    d1lgdp not a valid estimator
    r(198);


    I truly hope you can help me out. Would appreciate any bit of advice! thank you!

    Grateful,
    Sam

  • #2
    Looks like an incomplete installation of ivreg2. You need to tell us more about your installation and how you did it. Did you use ssc install (best) or did you do it by hand (bad idea unless you have no choice)? If the latter, try uninstalling and then
    Code:
    ssc install ivreg2, replace
    ssc install avar, replace
    ssc install ranktest, replace

    Comment


    • #3
      As to -ivregress-, your command syntax is wrong. ivregress should be followed by 2sls or gmm (or liml) and then only the name of the dependent variable and the rest.
      Type -help ivregress- in Stata for further help

      Comment

      Working...
      X