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

Description Usage Arguments Value

View source: R/scalar.R

Description

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

Usage

1
pspline.sample.scalars(model, predictors, calc.outcomes, samples = 100)

Arguments

model

model returned by gam or gamm

samples

number of simulations to run

time

time values at which the model will be evaluated during simulation

outcomes

scalar outcome generator function; see pspline.estimate.scalars for more info

Value

data frame with one row for each simulation; each row has pspline.sample column giving a unique ID for the simulation, and one column for each scalar outcome returned by outcomes


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