|
MCKL
Monte Carlo Kernel Library
|
Resampling algorithm. More...
#include <mckl/algorithm/resample.hpp>
Public Member Functions | |
| template<typename RNGType , typename InputIter , typename OutputIter > | |
| void | operator() (std::size_t N, std::size_t M, RNGType &rng, InputIter weight, OutputIter replication) const |
| Generate replication numbers from normalized weights. More... | |
Resampling algorithm.
Definition at line 516 of file resample.hpp.
|
inline |
Generate replication numbers from normalized weights.
| N | Sample size before resampling |
| M | Sample size after resampling |
| rng | An RNG engine |
| weight | N-vector of normalized weights |
| replication | N-vector of replication numbers |
Definition at line 527 of file resample.hpp.
1.8.13