Skip to content

Commit

Permalink
Add chain id
Browse files Browse the repository at this point in the history
  • Loading branch information
richfitz committed Nov 4, 2024
1 parent af3ff83 commit 6520b77
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions R/runner-simultaneous.R
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@ monty_run_chains_simultaneous2 <- function(chain_state, model, sampler,
history_pars <- array(NA_real_, c(n_pars, n_steps_record, n_chains))
history_density <- matrix(NA_real_, n_steps_record, n_chains)

chain_id <- seq_len(n_chains)

for (i in seq_len(steps$total)) {
chain_state <- sampler$step(chain_state, model, rng)
history_pars[, i, ] <- chain_state$pars
Expand Down

0 comments on commit 6520b77

Please sign in to comment.