write_JAGS_model: Write the JAGS model file

Description Usage Arguments Details

View source: R/write_JAGS_model.R

Description

write_JAGS_model creates "MixSIAR_model.txt", which is passed to JAGS by run_model when the "RUN MODEL" button is clicked in the GUI. Several model options will have already been specified when loading the mix and source data, but here is where the error term options are selected:

  1. Residual * Process (resid_err = TRUE, process_err = TRUE)

  2. Residual only (resid_err = TRUE, process_err = FALSE)

  3. Process only (resid_err = FALSE, process_err = TRUE)

Usage

1
2
3
4
5
6
7
write_JAGS_model(
  filename = "MixSIAR_model.txt",
  resid_err = TRUE,
  process_err = TRUE,
  mix,
  source
)

Arguments

filename

the JAGS model file is saved in the working directory as 'filename' (default is "MixSIAR_model.txt", but user can specify).

resid_err

T/F: include residual error in the model?

process_err

T/F: include process error in the model?

mix

output from load_mix_data

source

output from load_source_data

Details

WARNING messages are displayed if:


MixSIAR documentation built on Oct. 23, 2020, 6:45 p.m.