abf: Adapted Bagged Filter (ABF)

Description Usage Arguments Value Methods See Also Examples

Description

An algorithm for estimating the likelihood of a spatiotemporal partially-observed Markov process model. Running abf causes the algorithm to run bootstrap replicate jobs which each yield an imperfect adapted simulation. Simulating from the "adapted filter" distribution runs into a curse of dimensionality (COD) problem, which is mitigated by keeping particles in each replicate close to each other through resampling down to one particle per replicate at each observation time point. The adapted simulations are then weighted in a way that mitigates COD by making a weak coupling assumption to get an approximate filter distribution. As a by-product, we also get an estimate of the likelihood of the data.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
## S4 method for signature 'spatPomp'
abf(
  object,
  Nrep,
  Np,
  nbhd,
  tol = 1e-300,
  ...,
  verbose = getOption("verbose", FALSE)
)

## S4 method for signature 'abfd_spatPomp'
abf(
  object,
  Nrep,
  Np,
  nbhd,
  tol = 1e-300,
  ...,
  verbose = getOption("verbose", FALSE)
)

Arguments

object

A spatPomp object.

Nrep

The number of bootstrap replicates for the adapted simulations.

Np

The number of particles used within each replicate for the adapted simulations.

nbhd

A neighborhood function with three arguments: object, time and unit. The function should return a list of two-element vectors that represent space-time neighbors of (u,n), which is represented by c(unit,time). See example below for more details.

tol

If the resampling weight for a particle is zero due to floating-point precision issues, it is set to the value of tol since resampling has to be done.

...

If a params argument is specified, abf will estimate the likelihood at that parameter set instead of at coef(object).

verbose

logical; if TRUE, messages updating the user on progress will be printed to the console.

Value

Upon successful completion, abf() returns an object of class ‘abfd_spatPomp’ containing the algorithmic parameters used to run abf() and the estimated likelihood.

Methods

The following methods are available for such an object:

logLik

yields an estimate of the log-likelihood of the data under the model.

See Also

Other particle filter methods: abfir(), bpfilter(), enkf(), girf(), ienkf(), igirf(), iubf()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
# Create a simulation of a Brownian motion
b <- bm(U=3, N=10)

# Create a neighborhood function mapping a point in space-time
# to a list of neighboring points in space-time
bm_nbhd <- function(object, time, unit) {
  nbhd_list = list()
  if(time > 1 && unit > 1){
    nbhd_list = c(nbhd_list, list(c(unit-1, time-1)))
  }
  return(nbhd_list)
}

# Run ABF specified number of Monte Carlo replicates and particles per replicate
abfd_bm <- abf(b, Nrep=2, Np=10, nbhd=bm_nbhd)

# Get the likelihood estimate from ABF
logLik(abfd_bm)

spatPomp documentation built on Sept. 5, 2021, 5:35 p.m.