STARTlik: Likelihood estimation for starting points

Description Usage Arguments Details Functions Examples

View source: R/STARTlik.R

Description

The function STARTlik draws starting points from a given matrix of intervals (randomly sampled from a uniform distribution or on a grid). For each starting point, the likelihood is estimated from simulations.

Usage

1
2
3
4
STARTlik(int, sampling, N1, s.obs, simfun, Hfun = bw.nrd0.mult, kernel,
  nk, ...)

LIK(theta, simfun, nk, Hfun, kernel, s.obs, ...)

Arguments

int

matrix of intervals (2 columns, p rows)

sampling

character. One of "random" or "grid"

N1

number of starting points

s.obs

observed summary statistics

simfun

name of the function which is used for the simulation and computes the summary statistics

Hfun

function which computes the bandwidth matrix. Can be one of the functions in bw.R

kernel

kernel function for KDE

nk

number of simulations for the estimation of the likelihood with kernel density estimation

...

further parameters for simfun

Details

For points on a grid, the number of starting points N1 is approximate. For each dimension, round(N1^(1/p)) equally spaced points in the interval are chosen, with p being the number of dimensions.

Note that this could easily be parallelized. This is currently not implemented, since it depends on the system the program is run on.

Functions

Examples

1
2
3
4
5
int = matrix(c(-2, 5, 0, 2), ncol=2, nrow=2, byrow=T)

test_start_grid = STARTrandomlik(int, sampling="grid", N1=20, s.obs = c(2.2, 9), simfun = SIMpoisson_glmm, kernel = robust.unscaled.diagonal, nk=20, x = 1:3)

test_start_random = STARTrandomlik(int, sampling="random", N1=20, s.obs = c(2.2, 9), simfun = SIMpoisson_glmm, kernel = robust.unscaled.diagonal, nk=20, x = 1:3)

johannabertl/ApproxML documentation built on May 22, 2019, 2:19 p.m.