Learn R Programming

synlik (version 0.1.0)

synlik-class: synlik-class

Description

Basic class for simulation-based approximate inference using Synthetic Likelihood methods.

Usage

synlik(...)

Arguments

...
See section "Slots".

References

Simon N Wood. Statistical inference for noisy nonlinear ecological dynamic systems. Nature, 466(7310):1102--1104, 2010.

Examples

Run this code
#### Create Object
ricker_sl <- synlik(simulator = rickerSimul,
                    summaries = rickerStats,
                    param = c( logR = 3.8, logSigma = log(0.3), logPhi = log(10) ),
                    extraArgs = list("nObs" = 50, "nBurn" = 50),
                    plotFun = function(input, ...)
                                plot(drop(input), type = 'l', ylab = "Pop", xlab = "Time", ...)
)

# Simulate from the object
ricker_sl@data <- simulate(ricker_sl)
ricker_sl@extraArgs$obsData <- ricker_sl@data # Needed by WOOD2010 statistics

plot(ricker_sl)

Run the code above in your browser using DataLab