pspline.sample.timeseries: Runs simulations on an outbreak GAM/GAMM for the purpose of...

Description Usage Arguments Value

View source: R/timeseries.R

Description

This is mainly used internally by pspline.estimate.timeseries, but it's useful if you want to calculate summary statistics of simulation results other than the ones returned by pspline.estimate.timeseries.

Usage

1
pspline.sample.timeseries(model, predictors, outcome, samples = 100)

Arguments

model

model returned by gam or gamm

outcome

time series outcome generator function; see pspline.estimate.timeseries for more info

samples

number of simulations to run

time

time values at which the model will be evaluated during simulation

Value

matrix with one row for each simulation; each row contains the time series calculated by outcome for the corresponding simulation run


pspline.inference documentation built on Jan. 19, 2021, 5:07 p.m.