I'm running a logit model using the zelig package in R:
z.out <- zelig(trade961a ~ age962 + education962 + personal962 + economy962 + partisan962 + employment962 + union962 + home962 + market962 + race962 + income962, data=data96, model="logit")
The dependent variable, trade961a, is a dichotomous factor variable. All other variables are numeric.
I am interested in personal962, which is:
> str(personal962)
num [1:1714] 3 3 1 1 1 2 3 2 2 1 ...
so I run the following to simulate the probability of supporting international trade when personal962 is 1 (better):
x.out <- setx(z.out, personal962=1)
I get the following error message:
#Error in dta[complete.cases(mf), names(dta) %in% vars, drop = FALSE] : # incorrect number of dimensions
Any ideas on what I'm doing wrong?
Thanks
Abraham M.
Archive maintained by Robert King, hosted by
the discipline of
statistics at the
University of Newcastle,
Australia.
Archive generated by hypermail 2.2.0, at Sat 19 Jun 2010 - 21:20:33 GMT.
Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.