stanfit_needs_refit: Check if cached 'ideal_adaptor_stanfit' can be used.

View source: R/class-NIW-IA-stanfit.R

stanfit_needs_refitR Documentation

Check if cached ideal_adaptor_stanfit can be used.

Description

Checks whether a given cached fit can be used without refitting when file_refit = "on_change" is used.

Usage

stanfit_needs_refit(
  x,
  current_version = get_current_versions(),
  data = NULL,
  staninput = NULL,
  silent = FALSE,
  verbose = FALSE
)

Arguments

x

Old ideal_adaptor_stanfit object (e.g., loaded from file).

current_version

Current version of relevant packages. (default: will be automatically obtained from current packages).

data

New data to check consistency of factor level names. (default: NULL))

staninput

New Stan data (result of a call to standata). Pass NULL to avoid this data check. (default: NULL))

silent

Logical. If TRUE, no messages will be given. (default: FALSE))

verbose

Logical. If TRUE detailed report of the differences is printed to the console. (default: FALSE))

Details

fit differs from the given data and code.

Value

A boolean indicating whether a refit is needed.


hlplab/MVBeliefUpdatr documentation built on July 5, 2025, 6:42 a.m.