[R] Zicounts package
Achim Zeileis
Achim.Zeileis at wu-wien.ac.at
Thu Oct 25 11:23:40 CEST 2007
On Thu, 25 Oct 2007, Nic Surawski wrote:
> Dear R users,
>
> I have been using the zicounts package (verson 1.1.4) in R (version
> 2.4.1). I have been fitting zero inflated Poisson regressions to model
> the number of trips made by a household. Whilst I can get the best fit
> parameter set from zicounts, I can't get the package to return the
> fitted values for the model. I have attempted to calculate the fitted
> values from the optimal parameter set, but I'm not confident I got this
> correct.
>
> Can zicounts return fitted values for a ZIP model?
Not AFAICS. It seems to have neither a predict() nor a fitted() function
and the fitted values do not seem to be contained in the object either.
Instead of using zicounts(), you can also zeroinfl() from the "pscl"
package which has both, predicted() and fitted() methods. See also
vignette("countreg", package = "pscl")
> If not, what
> cumulative distribution should be used for the zero inflated (ie z)
> coefficients? Will a cumulative standard normal distribution do the
> job?
I'm not sure what you mean here, but I guess the answer is no. Check some
of the standard references for this, the vignette mentioned above gives
some information and severel references.
Z
More information about the R-help
mailing list