Dear Bugs users,
I am trying to do some linear trend analysis (in time) for indicators of
stream biological condition in Melbourne. The independent variable is
time, and I want to account for the possibility of first order
autocorrelation (AR1) in the residuals around the linear trend line. The
complicating factor is that over time there are missing samples
(non-sampled), and so I cannot treat the first order process as evenly
spaced. I was wondering if there was any generally accepted method for
dealing with unevenly spaced, but autocorrelated samples of this kind.
As a first step (assuming even spacing) I employed the approach from
Peter Congdon's (2001) Bayesian Statistical Modelling. In bugs code, the
specification of the fitted value is
mu[i] <- alpha + beta*t[i] + rho*(y[i-1] - alpha - beta*t[i-1])
where alpha is the regression intercept, beta the slope, rho the
autocorrelation coefficient, y the data, and t the time.
To address the occasionally uneven spacing of samples, I have tried
three approaches:
1) Modelling the missing data (same model but inserted NA's into the
data series for the missing points)
2) Dividing the rho*(y[i-1] - alpha - beta*t[i-1]) component of the
model by the time difference (tdiff[i] = t[i] - t[i-1]), which assumes
that autocorrelation is proportionally related to temporal separation
3) Multiplying rho*(y[i-1] - alpha - beta*t[i-1]) by theta^tdiff[i],
where theta has a uniform [0,1] prior and is estimated by the data,
which assumes exponential decay of autocorrelation with temporal
separation, but at a rate dictated by the data.
All three produce ostensibly similar results, although the estimate of
beta (main parameter of interest) is tightest for approach (3). Slightly
worryingly, the estimates for rho are all much lower than for the
initial model, even though my example data set has only one gap (a
spacing of 4 where the other 8 spacings are 1, n=10).
Any advice would be much appreciated.
Angus Webb
--
J Angus Webb
Research Fellow
Water Studies Centre
E-Water CRC & Department of Chemistry
Monash University
Clayton Campus, 3800
Vic, Australia
ph: +61 3 9905 4198
fax: +61 3 9905 4196
email: [log in to unmask]
-------------------------------------------------------------------
This list is for discussion of modelling issues and the BUGS software.
For help with crashes and error messages, first mail [log in to unmask]
To mail the BUGS list, mail to [log in to unmask]
Before mailing, please check the archive at www.jiscmail.ac.uk/lists/bugs.html
Please do not mail attachments to the list.
To leave the BUGS list, send LEAVE BUGS to [log in to unmask]
If this fails, mail [log in to unmask], NOT the whole list
|