No, zeroinfl() in pscl did not give me any errors when I ran the  
model.  So there may be a bug in zicounts.  Only problem now is how  
to interpret the zeroinfl model.  Am I correct in my understanding  
that zeroinfl runs both the poisson and binomial models without  
interactions?  I'm thinking along those lines since no interaction  
terms appear in either model.  If so, how do I check for any  
interactions?

Thanks.

Jim Milks

Graduate Student
Environmental Sciences Ph.D. Program
136 Biological Sciences
Wright State University
3640 Colonel Glenn Hwy
Dayton, OH 45435


On Aug 16, 2007, at 11:19 AM, Achim Zeileis wrote:

> On Thu, 16 Aug 2007, James R. Milks wrote:
>
>> Dr. Stevens,
>>
>> I've double-checked my variable lengths.  All of my variables
>> (Total.vines, Site, Species, and DBH) came in at 549.  I did correct
>> one problem in the data entry that had escaped my previous notice:
>> somehow the undergrad who entered all the data managed to make the
>> Acer negundo data split into two separate categories while still
>> appearing to use the same ACNE abbreviation.  When I made that
>> correction and re-ran zicounts, R gave me the following error  
>> messages:
>
> Hmm, I don't know about the error messages in zicounts, but you  
> could try to use the zeroinfl() implementation in package "pscl":
>   vines.zip <- zeroinfl(Total.vines ~ Site + Species + DBH | Site +
>     Species + DBH, data = sycamores.1)
> and see whether this produces a similar error.
> Z
>
>> > vines.zip<-zicounts(resp=Total.vines~.,x=~Site+Species+DBH,z=~Site
>> +Species+DBH,distname=ZIP,data=sycamores.1)
>>
>> Error in ifelse(y == 0, 1, y/mu) : dim<-: dims [product 12] do not
>> match the length of object [549]
>> In addition: Warning messages:
>> 1: longer object length is not a multiple of shorter object length
>> in: eta + offset
>> 2: longer object length is not a multiple of shorter object length
>> in: y/mu
>>
>> In addition, zicounts would not run a normal poisson regression on
>> the data, giving me the same error messages as the ZIP regression.
>> Doing a poisson regression with glm did not show any error messages.
>> However, the glm model with full interactions was still over- 
>> dispersed.
>>
>> Could the zicounts problem be that the individual sites and species
>> had different population sizes?  For instance, Site A had 149 trees,
>> site B had 55 trees, site C had 270 trees, and site D had 75 trees.
>> The species had similar discrepancies in population sizes, with
>> Platanus occidentalis and Acer negundo forming the majority of the
>> trees.
>>
>> Thanks for your help.
>>
>> Jim Milks
>>
>> Graduate Student
>> Environmental Sciences Ph.D. Program
>> 136 Biological Sciences
>> Wright State University
>> 3640 Colonel Glenn Hwy
>> Dayton, OH 45435
>>


        [[alternative HTML version deleted]]

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to