Description Usage Arguments Value Examples
View source: R/aggregate_simulation_results.R
This method is used to look at summary statistics such as average impact post-policy, and see how the predictive distribution compares to the observed.
1 2 3 4 5 6 7 | aggregate_simulation_results(
orig.data,
predictions,
outcomename,
summarizer = calculate_average_outcome,
...
)
|
orig.data |
The raw data (dataframe) |
predictions |
The results from process_outcome_model. |
outcomename |
Outcome to use. |
summarizer |
A function to calculate some summary quantity, Default: calculate_average_outcome |
... |
Extra arguments passed to the summarizer function. |
List of length two, with first item being the observed value of the test statistic and the second being a numeric vector representing the emperical reference distribution.
1 2 3 4 5 6 7 | predictions = process_outcome_model( "pbail", mecklenberg,
t0=0, R = 5,
summarize = FALSE, smooth=FALSE )
sstat = aggregate_simulation_results( orig.data = mecklenberg, outcomename = "pbail",
predictions = predictions, months = 1:18 )
sstat$t
sstat$t.obs
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.