Samples size objects of type T uniformly
See: http://en.wikipedia.org/wiki/Reservoir_sampling
This is a threadsafe version of a reservoir sampler that exposes an
interface in it's companion object for merging two samplers together in a
way that preserves the probabilistic properties of a reservoir sampler.
Samples size objects of type T uniformly See: http://en.wikipedia.org/wiki/Reservoir_sampling
This is a threadsafe version of a reservoir sampler that exposes an interface in it's companion object for merging two samplers together in a way that preserves the probabilistic properties of a reservoir sampler.