Given a dataframe of raw results from run_simulations, create summary statistics for the scenario. This is generally the most granular level of useful data for reporting and analysis (full simulation results are rarely directly helpful).

summarize_scenario(simulation_result)

summarize_scenarios(simulation_results)

Arguments

simulation_result

Results object for a single scenario.

simulation_results

Simulation results dataframe.

Value

Dataframe of summary statistics.

Details

Summary stats created include: * Mean/Min/Max/Median are calculated for loss events * Median/Max/VaR are calculated for annual loss expected (ALE) * Mean/Median/Max/Min are calculated for single loss expected (SLE) * Mean percentage of threat capability exceeding difficulty on successful threat events * Mean percentage of difficulty exceeding threat capability on defended events * Vulnerability percentage

Examples

data(mc_simulation_results)
# summarize a single scenario
summarize_scenario(mc_simulation_results$results[[1]])
#> # A tibble: 1 × 14
#>   loss_events_mean loss_events_median loss_events_min loss_events_max ale_median
#>              <dbl>              <dbl>           <int>           <int>      <dbl>
#> 1             7.48                  7               0              19    682568.
#> # … with 9 more variables: ale_max <dbl>, ale_var <dbl>, sle_mean <dbl>,
#> #   sle_median <dbl>, sle_min <dbl>, sle_max <dbl>, mean_tc_exceedance <dbl>,
#> #   mean_diff_exceedance <dbl>, mean_vuln <dbl>

# summarize all scenarios in a data frame
data(mc_simulation_results)
summarize_scenarios(mc_simulation_results)
#> # A tibble: 56 × 18
#>    scenario_id domain_id control_descriptions results           loss_events_mean
#>    <chr>       <chr>     <list>               <list>                       <dbl>
#>  1 RS-01       ORG       <named list [7]>     <tibble [1,000 ×…            7.48 
#>  2 RS-02       ORG       <named list [7]>     <tibble [1,000 ×…            7.48 
#>  3 RS-03       ORG       <named list [7]>     <tibble [1,000 ×…            1.72 
#>  4 RS-04       ORG       <named list [8]>     <tibble [1,000 ×…            2.73 
#>  5 RS-05       ORG       <named list [5]>     <tibble [1,000 ×…            4.21 
#>  6 RS-06       POL       <named list [4]>     <tibble [1,000 ×…            0    
#>  7 RS-07       POL       <named list [4]>     <tibble [1,000 ×…            0    
#>  8 RS-08       POL       <named list [4]>     <tibble [1,000 ×…            0.042
#>  9 RS-09       COMP      <named list [2]>     <tibble [1,000 ×…            0    
#> 10 RS-10       COMP      <named list [2]>     <tibble [1,000 ×…            1.90 
#> # … with 46 more rows, and 13 more variables: loss_events_median <dbl>,
#> #   loss_events_min <int>, loss_events_max <int>, ale_median <dbl>,
#> #   ale_max <dbl>, ale_var <dbl>, sle_mean <dbl>, sle_median <dbl>,
#> #   sle_min <dbl>, sle_max <dbl>, mean_tc_exceedance <dbl>,
#> #   mean_diff_exceedance <dbl>, mean_vuln <dbl>