sample_3d_grid_scan: Sample Grid Scan

View source: R/estimation.R

sample_3d_grid_scanR Documentation

Sample Grid Scan

Description

Take a grid search produced by scan_R0_date_Meff and sample n_sample_pairs from the parameter grid uses based on their probability. For each parameter pair chosen, run particle filter with num_particles and sample 1 trajectory

Usage

sample_3d_grid_scan(
  scan_results,
  n_sample_pairs = 10,
  n_particles = 100,
  forecast_days = 0,
  full_output = FALSE
)

Arguments

scan_results

Output of scan_R0_date_Meff.

n_sample_pairs

Number of parameter pairs to be sampled. This will determine how many trajectories are returned. Integer. Default = 10. This will determine how many trajectories are returned.

n_particles

Number of particles. Positive Integer. Default = 100

forecast_days

Number of days being forecast. Default = 0

full_output

Logical, indicating whether the full model output, including the state and the declared outputs are returned. Deafult = FALSE

Value

list. First element (trajectories) is a 3 dimensional array of trajectories (time, state, tranjectories). Second element (param_grid) is the parameters chosen when sampling from the scan_results grid and the third dimension (inputs) is a list of model inputs.


mrc-ide/squire documentation built on Sept. 10, 2022, 1:11 a.m.