getConfig: Get SHG Configuration

getConfigR Documentation

Get SHG Configuration

Description

Returns the current configuration of the SHG instance as an R list. Can include debug information when debug=TRUE.

Arguments

debug

Logical. If TRUE, includes additional debug information such as RNG state fingerprint, package version, system info, and memory usage. If not provided, defaults to FALSE.

Details

Get current SHG configuration

Value

A list containing the current intent configuration including: config_version, rng_strategy, number_of_segments, num_threads, seeds, input file paths (including mortality_filename), smok_params_source, mort_params_source, and mort_params_type (from load_params, else NA), immediate_cessation_year, inferred cohort_year (single-cohort runs; otherwise NA), repeat/race/sex after runSimFromFixedValues (otherwise NA), and timestamp. This method returns currently applied values (including unresolved auto values such as -1 for segments/threads). Use getReproConfig() to export effective runtime values from the last completed simulation. seeds always returns concrete values (explicit user seeds or defaults). If debug=TRUE, also includes rng_state_fingerprint, package_version, package_source, r_version, platform, and memory_usage.

Examples

shg <- new(SHGInterface)
shg$input_data_folder <- system.file("extdata", "2018", package = "SmokingHistoryGenerator")
shg$rng_strategy <- "RngStream"
shg$number_of_segments <- 4
config <- shg$getConfig()
names(config)

SmokingHistoryGenerator documentation built on June 13, 2026, 1:08 a.m.