I am looking for help with more efficient modeling of an intervention study
on multiple species. I am particularly interested in evaluating the
intervention effect for each species. The model below runs well for one
species at a time. Any advice/examples would be greatly appreciated.
model{
##Priors
beta1 ~ dnorm(0, 1.0E-6) ##intervention effect
beta2 ~ dnorm(0, 1.0E-6) ##year trend
betas ~ dnorm(0, 1.0E-6) ##spec effect
for(k in 1: ncounts) {
noise[k] ~ dnorm(0.0, taunoise)
log(lambda[k]) <- rte[route[k]] + obs[obser[k]] + beta1*intervention[k]+
beta2*(year[k]-fixedyear) +noise[k]
count[k] ~ dpois(lambda[k])
err[k] <- pow(count[k]-lambda[k],2)/lambda[k]
eps[k] <- count[k]-lambda[k]
#residual
resid[k] <- taunoise*(count[k]-lambda[k])
#standardized residual
aresid[k] <- abs(count[k]-lambda[k])
}
taunoise ~ dgamma(0.001, 0.001)
#---------------------------------------------------------#
#### route effects ######
for(r in 1:nroutes) {
rte[r] ~ dnorm(0.0, taurte) }
taurte ~ dgamma(0.5, 0.0005)
#---------------------------------------------------------#
#### observer effects ######
for( i in 1:nobservers) {
obs[i] ~ dnorm(0.0, tauobs)
}
tauobs ~ dgamma(0.001, 0.001)
-------------------------------------------------------------------
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
|