Skip to contents

Reports where the casualties stood when the clock stopped, which is the quantity the published reference distribution describes. A casualty's end state is the last board area it had entered by the horizon; one that never cleared triage counts as "not_seen".

Usage

# S3 method for class 'game_run'
summary(object, reference = FALSE, version = c("2.0", "1.0"), ...)

Arguments

object

A game_run from sdt_simulate().

reference

If TRUE, fold the areas onto the published reporting locations and add the reference proportion beside the observed one, with their difference.

version

Which evaluated version of the exercise to compare against, "2.0" or "1.0". Only used when reference = TRUE.

...

These dots are for future extensions and must be empty.

Value

A tibble::tibble() with columns area, label, n and proportion; when reference = TRUE, also reference and difference. Every area is present even at a zero count, so the shape does not depend on the run.

Details

Two granularities are available. By default the tibble has one row per board area. With reference = TRUE it is folded onto the eight locations the source reports, because those are the only ones a published proportion exists for: the two emergency-department areas become one, and the green treatment area joins the ward. Both pairings are recorded in sdt_reference("defaults")$end_state_map rather than being applied here, so they can be inspected and argued with.

See also

sdt_reference() for the published values and their provenance.

Examples

co <- sdt_synthetic_cohort(n = 40, seed = 1)
run <- sdt_simulate(sdt_scenario(co), replications = 2, seed = 1,
                    verbose = FALSE)
summary(run)
#> # A tibble: 12 × 4
#>    area        label               n proportion
#>    <chr>       <chr>           <int>      <dbl>
#>  1 triage      Screening          34     0.425 
#>  2 ed_red      ED red              6     0.075 
#>  3 ed_yellow   ED yellow           9     0.112 
#>  4 diagnostics Radiology          13     0.162 
#>  5 or          Operating room      4     0.05  
#>  6 recovery    Recovery            0     0     
#>  7 icu_imc     ICU / IMC           1     0.0125
#>  8 ward        Ward                5     0.0625
#>  9 green_area  Green area          8     0.1   
#> 10 morgue      Mortuary            0     0     
#> 11 external    Transferred out     0     0     
#> 12 not_seen    Not yet seen        0     0     
summary(run, reference = TRUE)
#> # A tibble: 8 × 6
#>   area        label                    n proportion reference difference
#>   <chr>       <chr>                <int>      <dbl>     <dbl>      <dbl>
#> 1 triage      Screening               34     0.425       0.08     0.345 
#> 2 ed          Emergency department    15     0.188       0.16     0.0275
#> 3 diagnostics Radiology               13     0.162       0.04     0.122 
#> 4 or          Operating room           4     0.05        0.11    -0.06  
#> 5 recovery    Recovery                 0     0           0.01    -0.01  
#> 6 icu_imc     ICU / IMC                1     0.0125      0.23    -0.218 
#> 7 ward        Ward                    13     0.162       0.35    -0.187 
#> 8 not_seen    Not yet seen             0     0           0        0     
summary(run, reference = TRUE, version = "1.0")
#> # A tibble: 8 × 6
#>   area        label                    n proportion reference difference
#>   <chr>       <chr>                <int>      <dbl>     <dbl>      <dbl>
#> 1 triage      Screening               34     0.425       0.15     0.275 
#> 2 ed          Emergency department    15     0.188       0.17     0.0175
#> 3 diagnostics Radiology               13     0.162       0.06     0.103 
#> 4 or          Operating room           4     0.05        0.09    -0.04  
#> 5 recovery    Recovery                 0     0           0.01    -0.01  
#> 6 icu_imc     ICU / IMC                1     0.0125      0.2     -0.188 
#> 7 ward        Ward                    13     0.162       0.31    -0.148 
#> 8 not_seen    Not yet seen             0     0           0.03    -0.03