Description Usage Arguments Value
View source: R/resampleResidual.R
Also called remainder sampling, assuming that for particles with large weights new particle can be assighed without drawing. In the frist part of resampling step, samples with weights larger than 1/N will be kept and reduced by a multiple of 1/N. In the second part, we normalize the weights an do simple resampling.
1 | resampleResidual(w, N)
|
w |
Sample weights |
N |
Number of particles. Defalut is the length of w. |
indx Return the chosen index.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.