prep_pbar: Initialize and tick through the progress bar

View source: R/TS.R

prep_pbarR Documentation

Initialize and tick through the progress bar

Description

prep_pbar creates and update_pbar steps through the progress bars (if desired) in TS

Usage

prep_pbar(control = list(), bar_type = "rho", nr = NULL)

update_pbar(pbar, control = list())

Arguments

control

A list of parameters to control the fitting of the Time Series model including the parallel tempering Markov Chain Monte Carlo (ptMCMC) controls. Values not input assume defaults set by TS_control. Of use here is quiet which is a a logical indicator of whether there should be information (i.e. the progress bar) printed during the run or not. Default is TRUE.

bar_type

"rho" (for change point locations) or "eta" (for regressors).

nr

integer number of unique realizations, needed when bar_type = "eta".

pbar

The progress bar object returned from prep_pbar.

Value

prep_pbar: the initialized progress bar object.

update_pbar: the ticked-forward pbar.

Examples

  pb <- prep_pbar(control = list(nit = 2)); pb
  pb <- update_pbar(pb); pb
  pb <- update_pbar(pb); pb


LDATS documentation built on Sept. 19, 2023, 5:08 p.m.