[R] autoregressive poisson process

vito muggeo vito.muggeo at giustizia.it
Wed Dec 11 08:45:03 CET 2002


>I am trying to find a package that can estimate
>an autoregressive model for discrete data.  I am
>imagining a Poisson or Gamma process in which the
>mean (say mu) follows a process such as

>mu_t = a + b*x + c*mu_{t-1}

>Suppose I have data on the time-series Poisson
>outcomes and x and would like to obtain ML estimates
>for b and c.

>Does anyone know of a package that can do this or
>something similar in R?  My first (naive) instinct was
>to use glm and the lagged outcome as a regressor,
>but that isn't quite right.

Right, it should not be the best choice, unless you don't have negative
aucorrelation between the data.

Otherwise you could fit the lagged residuals, namely something like

log E[Y_t]=\eta_t+ r*(log y_{t-1}-\eta_{t-1})

where \eta_t is the linear predictor and r is the autoregression parameter.

You could build a while() loop to fit the model above, it should not be very
difficult; otherwise see the gar() function in gnlr package by J.Lindsey,
although I didn't test it.

Hope this helps,
best,
vito

Hope this help

----- Original Message -----
From: Michael Roberts
To: R-help at stat.math.ethz.ch
Sent: Tuesday, December 10, 2002 1:41 PM
Subject: [R] autoregressive poisson process


Dear R users,


Thanks very much,

Michael Roberts




More information about the R-help mailing list