IQSS / Zelig

A statistical framework that serves as a common interface to a large range of models
http://zeligproject.org
109 stars 43 forks source link

mlogit simulations and zelig_qi_to_df #323

Open lfggraca opened 6 years ago

lfggraca commented 6 years ago

Hi, I am having some trouble extracting qi from a mlogit model. When I try to use the zelig_qi_to_df function it throws me an error "Error: $ operator not defined for this S4 class". I am not quite sure how to deal with this.

Here goes a similar code with data(mexico)

data("mexico") test <- zelig(as.factor(vote88) ~ pristr + age + school + female, model = "mlogit", data= mexico, verbose = FALSE) female <- setx(test,female = 1) male <- setx(test, female = 0) test1 <- sim(test, x=female, x1=male) summary(test1) zelig_qi_to_df(test1) head(test1)

Best

cvaccari commented 6 years ago

Hello, I am having the exact same problem and I would hugely appreciate if it could be fixed. Thanks!

hbahamonde commented 4 years ago

Same. Also using mlogit.