aggregateModel: Aggregate model results at different time points

View source: R/mcmc.R

aggregateModelR Documentation

Aggregate model results at different time points

Description

This function is useful to convert the mcmc results into aggregated results, such as mean, variance etc.

Usage

aggregateModel(func, batch, aggregate, ...)

Arguments

func

The function that gets called for each set of parameters (e.g. infectionODEs)

batch

Posterior parameters samples resulting from mcmc. Each row is a set of parameters

aggregate

The aggragation function (i.e. mean, var etc). If the function returns a list, then the names are used in the return value

...

Extra parameters passed to func.

Value

Returns a data.frame in long format, with for each time point, interval, column.ID the value


MJomaba/flu-evidence-synthesis documentation built on April 26, 2022, 11:12 p.m.