systematic_sample: Systematic resampling function

View source: R/AMIS_steps.R

systematic_sampleR Documentation

Systematic resampling function

Description

Implement systematic resampling to reduce variance in weighted particle selection

Usage

systematic_sample(nsamples, weights, log = F)

Arguments

nsamples

number of samples to draw

weights

vector of length equal to the number of particles, containing their weights

log

logical indicating if weights are log-weights

Value

vector of indices of the sampled particles


OxfordRSE/trachomAMIS documentation built on Aug. 1, 2022, 10:21 p.m.