Good morning
If I run
<<<
susan.lsmixed.out <- zelig(formula = unprot_vag_sex ~ married + age + TREATMENT.ARM*time + highest_grade + income + tag(1|id),
data = susanMI.out$imputations, model = "ls.mixed")
summary(susan.lsmixed.out)
>>>>
I get an error
Error in x$coef : $ operator is invalid for atomic vectors
Searching the archives, I see that others have had similar problems. Is there a workaround?
summary(susan.lsmixed.out[[1]])
works fine; should I then average across the five imputed data sets?
thanks!
Peter
Peter L. Flom, PhD
Statistical Consultant
Website: http://www DOT statisticalanalysisconsulting DOT com/
Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
Twitter: @peterflom
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/
Hey all-
I'm trying to run a weighted Poisson model (I did full matching and
need to weight the model). The code looks like this:
z.out <- zelig(polact ~ treat + pid_str + q44 + q52 + contact,
weights="weights", data = mi(ds1, ds2, ds3, ds4, ds5), model =
"poisson.survey")
I get these errors:
Error in 1/as.matrix(weights) : non-numeric argument to binary operator
In addition: Warning message:
In poisson(link = link) : use of poisson(link=link) is deprecated
I am running version 3.4-5 in Windows 7.
Any thoughts?
Thanks much,
-c
--
Casey A. Klofstad
University of Miami
Department of Political Science
Coral Gables, FL
klofstad(a)gmail.com
http://www.as.miami.edu/personal/cklofstad/
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/
Dear Zelig users,
I've recently started using Zelig (and R). I wanted to interpret multiplicative interaction effects in a negative binomial regression (panel random effects). After looking at the Zelig manual, I saw that ".mixed" or ".gee" procedures can be used with some non-linear models (such as logit and poisson), but not the negative binomial. I wanted to confirm if I understood this correctly. And I would be interested to hear your suggestions on how to correctly assess significance of interaction effects in a negative binomial regression model with random effects.
Thank you,
Hakan Ener
Asst. Prof.
IESE Business School
Barcelona, Spain
Hi all,
Please note that the following bug regarding survival regression models
with clustering has been fixed. It was actually an error in the survival
package and the most recent version of it fixes this error. So, please
install the latest version of survival package and everything should run
smoothly. (And of course please install the latest version of Zelig too
via:
install.packages("Zelig", repos = "http://gking.harvard.edu")
Thanks,
Kosuke
--
Department of Politics
Princeton University
http://imai.princeton.edu
---------- Forwarded message ----------
From: sayan dasgupta <kittudg(a)gmail.com>
Date: Thu, Nov 5, 2009 at 12:31 AM
Subject: Re: [zelig] zelig demo (Robust)
To: Olivia Lau <olivia.lau(a)post.harvard.edu>
The attached Text file contains the output of the function tracback()
Thamks again for your help
Sayan
Thanks!
Peter
-----Original Message-----
>From: Kosuke Imai <kimai(a)Princeton.Edu>
>Sent: Jan 18, 2010 4:01 PM
>To: Peter Flom <peterflomconsulting(a)mindspring.com>
>Cc: zelig(a)lists.gking.harvard.edu
>Subject: Re: [zelig] summary with imputations bug ... any workarounds?
>
>The point estimates can be obtained by running Zelig for each imputed
>model and calculating the mean of all five estimates for each parameter.
>Standard errors are a little tricky: see Little and Rubin or Schafer's
>books on multiple imputation for the formulae. If you know how to do some
>R programming, you can combine all simulation draws from each of the five
>runs. And then calculate whatever the quantities you like.
>
>Good luck,
>Kosuke
>
>--
>Department of Politics
>Princeton University
>http://imai.princeton.edu
>
>On Mon, 18 Jan 2010, Peter Flom wrote:
>
>> OK, thanks.... any suggestions in the meantime?
>>
>> I can use SAS, but I don't like their imputation methods in this case.
>>
>> Or maybe I can just look at the five outputs, and see if any were much different from the results with casewise deletion?
>>
>> Thanks
>>
>> Peter
>>
>>
>> -----Original Message-----
>>> From: Kosuke Imai <kimai(a)Princeton.Edu>
>>> Sent: Jan 18, 2010 3:13 PM
>>> To: Peter Flom <peterflomconsulting(a)mindspring.com>
>>> Cc: zelig(a)lists.gking.harvard.edu
>>> Subject: Re: [zelig] summary with imputations bug ... any workarounds?
>>>
>>> Unfortunately, mixed effects models are not currently compartible with
>>> multiply imputed data sets. It's on our to-do list...
>>>
>>> Kosuke
>>>
>>> --
>>> Department of Politics
>>> Princeton University
>>> http://imai.princeton.edu
>>>
>>> On Fri, 15 Jan 2010, Peter Flom wrote:
>>>
>>>> Good morning
>>>>
>>>> If I run
>>>>
>>>> <<<
>>>> susan.lsmixed.out <- zelig(formula = unprot_vag_sex ~ married + age + TREATMENT.ARM*time + highest_grade + income + tag(1|id),
>>>> data = susanMI.out$imputations, model = "ls.mixed")
>>>>
>>>>
>>>> summary(susan.lsmixed.out)
>>>>>>>>
>>>>
>>>> I get an error
>>>>
>>>> Error in x$coef : $ operator is invalid for atomic vectors
>>>>
>>>> Searching the archives, I see that others have had similar problems. Is there a workaround?
>>>>
>>>> summary(susan.lsmixed.out[[1]])
>>>>
>>>> works fine; should I then average across the five imputed data sets?
>>>>
>>>> thanks!
>>>>
>>>> Peter
>>>>
>>>> Peter L. Flom, PhD
>>>> Statistical Consultant
>>>> Website: http://www DOT statisticalanalysisconsulting DOT com/
>>>> Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
>>>> Twitter: @peterflom
>>>>
>>>> -
>>>> Zelig Mailing List, served by Harvard-MIT Data Center
>>>> Send messages: zelig(a)lists.gking.harvard.edu
>>>> [un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
>>>> Zelig program information: http://gking.harvard.edu/zelig/
>>>>
>>>
>>> -
>>> Zelig Mailing List, served by Harvard-MIT Data Center
>>> Send messages: zelig(a)lists.gking.harvard.edu
>>> [un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
>>> Zelig program information: http://gking.harvard.edu/zelig/
>>
>>
>> Peter L. Flom, PhD
>> Statistical Consultant
>> Website: http://www DOT statisticalanalysisconsulting DOT com/
>> Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
>> Twitter: @peterflom
>>
Peter L. Flom, PhD
Statistical Consultant
Website: http://www DOT statisticalanalysisconsulting DOT com/
Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
Twitter: @peterflom
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/
The point estimates can be obtained by running Zelig for each imputed
model and calculating the mean of all five estimates for each parameter.
Standard errors are a little tricky: see Little and Rubin or Schafer's
books on multiple imputation for the formulae. If you know how to do some
R programming, you can combine all simulation draws from each of the five
runs. And then calculate whatever the quantities you like.
Good luck,
Kosuke
--
Department of Politics
Princeton University
http://imai.princeton.edu
On Mon, 18 Jan 2010, Peter Flom wrote:
> OK, thanks.... any suggestions in the meantime?
>
> I can use SAS, but I don't like their imputation methods in this case.
>
> Or maybe I can just look at the five outputs, and see if any were much different from the results with casewise deletion?
>
> Thanks
>
> Peter
>
>
> -----Original Message-----
>> From: Kosuke Imai <kimai(a)Princeton.Edu>
>> Sent: Jan 18, 2010 3:13 PM
>> To: Peter Flom <peterflomconsulting(a)mindspring.com>
>> Cc: zelig(a)lists.gking.harvard.edu
>> Subject: Re: [zelig] summary with imputations bug ... any workarounds?
>>
>> Unfortunately, mixed effects models are not currently compartible with
>> multiply imputed data sets. It's on our to-do list...
>>
>> Kosuke
>>
>> --
>> Department of Politics
>> Princeton University
>> http://imai.princeton.edu
>>
>> On Fri, 15 Jan 2010, Peter Flom wrote:
>>
>>> Good morning
>>>
>>> If I run
>>>
>>> <<<
>>> susan.lsmixed.out <- zelig(formula = unprot_vag_sex ~ married + age + TREATMENT.ARM*time + highest_grade + income + tag(1|id),
>>> data = susanMI.out$imputations, model = "ls.mixed")
>>>
>>>
>>> summary(susan.lsmixed.out)
>>>>>>>
>>>
>>> I get an error
>>>
>>> Error in x$coef : $ operator is invalid for atomic vectors
>>>
>>> Searching the archives, I see that others have had similar problems. Is there a workaround?
>>>
>>> summary(susan.lsmixed.out[[1]])
>>>
>>> works fine; should I then average across the five imputed data sets?
>>>
>>> thanks!
>>>
>>> Peter
>>>
>>> Peter L. Flom, PhD
>>> Statistical Consultant
>>> Website: http://www DOT statisticalanalysisconsulting DOT com/
>>> Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
>>> Twitter: @peterflom
>>>
>>> -
>>> Zelig Mailing List, served by Harvard-MIT Data Center
>>> Send messages: zelig(a)lists.gking.harvard.edu
>>> [un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
>>> Zelig program information: http://gking.harvard.edu/zelig/
>>>
>>
>> -
>> Zelig Mailing List, served by Harvard-MIT Data Center
>> Send messages: zelig(a)lists.gking.harvard.edu
>> [un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
>> Zelig program information: http://gking.harvard.edu/zelig/
>
>
> Peter L. Flom, PhD
> Statistical Consultant
> Website: http://www DOT statisticalanalysisconsulting DOT com/
> Writing; http://www.associatedcontent.com/user/582880/peter_flom.html
> Twitter: @peterflom
>
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/
Hi,
Is Zelig supported for R on MAC OS Snow Leopard (v10.6)? Thanks.
Alex.
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/
Hi, I noticed that there doesn't seem to be an ids option for the
zelig function when the model is oprobit, does anyone know a way to
cluster the errors given by the zelig model? Or know of a function
from another package that would do the trick? Thanks, John.
-
Zelig Mailing List, served by Harvard-MIT Data Center
Send messages: zelig(a)lists.gking.harvard.edu
[un]subscribe Options: http://lists.gking.harvard.edu/?info=zelig
Zelig program information: http://gking.harvard.edu/zelig/