Package-level declarations

Types

Link copied to clipboard
class BernoulliPicker<T>(successProbability: Double, successOption: T, failureOption: T, stream: RNStreamIfc = KSLRandom.nextRNStream()) : RElementIfc<T>

Allows the picking between two alternatives according to a Bernoulli process.

Link copied to clipboard
class DEmpiricalList<T>(elements: List<T>, theCDF: DoubleArray, stream: RNStreamIfc = KSLRandom.nextRNStream()) : RElementIfc<T>

Randomly selects the elements in the list according to a supplied CDF across the items

Link copied to clipboard
class DPopulation(elements: DoubleArray, stream: RNStreamIfc = KSLRandom.nextRNStream(), name: String? = null) : RandomIfc, SampleIfc, ParametersIfc, IdentityIfc

A DPopulation is a population of doubles that can be sampled from and permuted.

Link copied to clipboard
class DUniformList<T>(elements: MutableList<T> = mutableListOf(), stream: RNStreamIfc = KSLRandom.nextRNStream()) : RList<T>
Link copied to clipboard

Defines sampling of random elements. Implementers must ensure that non-null random elements are sampled.

Link copied to clipboard
class REmpiricalMap<K, V>(map: Map<K, V>, theCDF: DoubleArray, stream: RNStreamIfc = KSLRandom.nextRNStream()) : Map<K, V> , RElementIfc<V>

Permits random sampling of the elements of the map according to the supplied CDF over the keys. The number of elements in the CDF must be the same as the number of keys in the map. The map must have at least one element. The CDF array must be a valid cumulative probability distribution.

Link copied to clipboard
abstract class RList<T>(val elements: MutableList<T>, stream: RNStreamIfc = KSLRandom.nextRNStream()) : RListIfc<T> , MutableList<T>
Link copied to clipboard
interface RListIfc<T> : RElementIfc<T> , MutableList<T>
Link copied to clipboard
class RMap<K, V>(map: Map<K, V>, stream: RNStreamIfc = KSLRandom.nextRNStream()) : Map<K, V> , RElementIfc<V>

Permits random sampling of the elements of the map. Elements are randomly sampled with equal probability based on the number of element in the map. There must be at least one element to permit random sampling.

Functions

Link copied to clipboard
fun main()
fun main()