MC.summary.agg | R Documentation |
A function that computes the summary statistics of aggregated Monte Carlo simulation result.
MC.summary.agg(summ, det, delta, func.agg, func.agg.p)
summ |
A |
det |
A |
delta |
A |
func.agg |
The aggregation function to be applied to the |
func.agg.p |
The aggregation function to be applied to the independient variable |
A dataframe
containing the summ
data aggregated to the level defined by delta
J.A. Torres-Matallana
See Also as MC.summary
library(stUPscales)
library(EmiStatR)
data(P1)
colnames(P1)
new_data <- t(matrix(data = rep(runif(nrow(P1), 10, 100), 5), nrow = nrow(P1), ncol = 5))
new_summary <- MC.summary(p1 = P1, data = new_data)
str(new_summary)
head(new_summary)
# deterministic simulation
det <- rnorm(nrow(P1), 45, .15)
# level of aggregation
delta <- 60*2 # 2 hours
new_summary_agg <- MC.summary.agg(summ = new_summary, det, delta, func.agg = mean, func.agg.p = sum)
str(new_summary_agg)
head(new_summary_agg)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.