minor edits plus separated stan bugs jags code