jg_block_names-set: Set block names in JAGS model code

Description Usage Arguments Value See Also Examples

Description

Sets block names in JAGS model code. Throws an error if unbalanced brackets. Strips out comments.

Usage

1
jg_block_names(x) <- value

Arguments

x

string of JAGS model code

value

character vector of block names

Value

Modified JAGS model code.

See Also

juggler and jg_blocks

Examples

1
2
3
 x <- "data {X <- 2} model { Y ~ dpois(X) }"
jg_block_names(x) <- c("settings", "model")
print(x)

poissonconsulting/juggler documentation built on Feb. 18, 2021, 11:12 p.m.