Yes, certainly you can use quasi-likelihood approach to take into account
for the overdispersion. Unfortunately, Zelig does not have zero-inflated
models so if you want to use those models you would have to look
elsewhere...
Kosuke
--
Department of Politics
Princeton University
Dear professor Imai,
Thanks a lot for the reply!
I switched from poisson.mixed to poisson.mixed. But I am still a little unsure about
several things, one concerning the over-dispersion issue, and another concerning the
inflated-zero.
My data is to examine whether a country's world system position significantly
increases the importance of cities located in the country, and whether such effects
increased or declined across time. So, I have two levels, country and city. Data are
measured longitudinally. The importance of cities (variable name: Outdegree) can be
regarded as counts--which is--0, 1, 2, 3, ....... It is heavily zero-inflated (about 70%
is zero). Wsln80(wsln90, wsln00) is the world system variables (in each time point), and
is log-transformed. I set the model as following:
z.out <- zelig(Outdegree ~ WSln80 + WSln90 + WSln00 + Y1990 + Y2000 +
tag(1|Country_Code) + tag(1 | cityid), data = wc3, model = "poisson.mixed",
family = quasipoisson(link="log"))
I add "family = quasipoisson" to take into account the overdispersion (for the
variable outdegree, its standard deviation is 10 times of its mean).
I have two questions:
1. Is my way dealing with overdispersion correct or/and sufficient?
2. My data is zero-inflated. How to take this nature of my data into account on the basis
of current model? Or do I have to switch to other models?
I hope you can give some advice!
Thank you very much!
Xiulian
-----Original Message-----
From: Kosuke Imai [mailto:kimai@Princeton.EDU]
Sent: Sunday, March 29, 2009 3:42 PM
To: Xiulian Ma
Cc: zelig(a)lists.gking.harvard.edu
Subject: Re: [zelig] Can I run gamma mixed model in zelig for zero-augmented data?
Urgent!
Unfortunately, the gamma mixed model in the package cannot deal with
zero's in the outcome variable.
Kosuke
--
Department of Politics
Princeton University
http://imai.princeton.edu
On Thu, 26 Mar 2009, Xiulian Ma wrote:
Dear All,
I try to run a gamma mixed model in zelig, but got the following error message:
Error in eval(expr, envir, enclos) :
non-positive values not allowed for the gamma family
Besides the dependent structure among observations, a large proportion (about 75%) of my
response variable is zero. I was advised that zelig gamma mixed model can handle my
zero-augmented data. Is that true?
The code for my model is:
z.out1 <- zelig (OutDegr ~ Pr65 + Pr80 + Pr00 + Semipr65 + Semipr80 + Semipr00 +
tag(1 | cityid), data = wc3, model = "gamma.mixed")
Could anybody give me some help?
Thank you very much!
Xiulian
-
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: