output_plot: Emulator Plots with Outputs

Description Usage Arguments Details Value Examples

Description

Plots emulator outputs across a set of points, with the corresponding observations overlaid (with the appropriate uncertainty).

Usage

1
output_plot(emulators, targets, points = NULL, npoints = 1000)

Arguments

emulators

A list of Emulator objects

targets

A named list of observations, given in the usual form

points

A list of points at which the emulators should be evaluated. Default: NULL

npoints

If no points provided, how many input points to evaluate? Default: 1000

Details

If no points are provided, then npoints points are uniformly sampled from the input region. Else the provided points are used - for example, if a non-implausible space is known.

Value

A ggplot object.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
 ranges <- list(aSI = c(0.1, 0.8), aIR = c(0, 0.5), aSR = c(0, 0.05))
 outputs <- c('nS','nI','nR')
 targets <- list(
  nS = list(val = 281, sigma = 10.43),
  nI = list(val = 30, sigma = 11.16),
  nR = list(val = 689, sigma = 14.32)
 )
 ems <- emulator_from_data(GillespieSIR, outputs, ranges,
  deltas = rep(0.1, 3), quadratic = TRUE)
 t_ems <- purrr::map(seq_along(ems), ~ems[[.]]$adjust(GillespieSIR, outputs[.]))
 output_plot(t_ems, targets)

Tandethsquire/emulatorr documentation built on April 12, 2021, 1:08 a.m.