Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: ivqreg error code and additional variables
From
Katie Farrin <[email protected]>
To
[email protected]
Subject
st: ivqreg error code and additional variables
Date
Sun, 26 May 2013 12:49:02 -0400
I am attempting to run an instrumental variables quantile regression
model using the user-written program ivqreg. I have the Stata Journal
article that describes the syntax and how the code operates, but I am
getting an odd error and no output.
When I run the following code:
. ivqreg ln_dietarydiversity male married hh_bus_profits
tot_livestock_sales value_maize age_hh_head remittances other_income
(tobacco = dist_urban_center), robust
I get an error r(110) "dhat already defined." I am not a programmer,
and have looked at the user-written program and see that dhat is the
variable the program generates for the first-stage regression results
(regressing the endogenous variable on the instrument). These
estimates are stored and dhat is a new variable in my working data.
However, I cannot figure out what is going wrong in the programming
code to generate this error. I have attempted to contact the author
of the code but have not gotten a response; it seems the code he used
did work as he generated results with it, so I'm at a loss as to why I
cannot successfully run it.
I have the full program but did not want to paste the whole thing on
this email - if it would help to solve my problem please let me know.
I'm hoping someone has done this type of regression before and can
direct me as to how I can proceed.
Best,
Katie
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/