for (i in 1:160) {
situps ~ dnorm(mu,prec[gender+1]);
mu <- b0+b1[gender]+b2[health]+b1b2[health,gender];
}
b0 ~ dnorm(0,.001);
for (i in 1:4) {
b2 ~ dnorm(0,.001);
}
for (j in 1:2) {
b1[j] ~ dnorm(0,.001);
prec[j] <- pow(sigma[j],-2);
sigma[j] ~ dunif(0,10);
}
for (i in 1:4) {
for (j in 1:2) {
b1b2[i,j] ~ dnorm(0,.001);
}
}
I'm not sure why this gives me the error "array index is less than one" because I clearly have all of my arrays starting at 1. Any ideas?