public class RandomKt
| Modifier and Type | Method and Description |
|---|---|
static double |
quantile(F64Array $receiver,
double q,
org.apache.commons.math3.random.RandomGenerator randomGenerator)
Computes the
q-th order statistic over this 1-D array. |
static void |
shuffle(F64Array $receiver,
org.apache.commons.math3.random.RandomGenerator randomGenerator)
Randomly permutes the elements of this 1-D array.
|
public static double quantile(@NotNull
F64Array $receiver,
double q,
@NotNull
org.apache.commons.math3.random.RandomGenerator randomGenerator)
Computes the q-th order statistic over this 1-D array.
The implementation follows that of Commons Math. See JavaDoc of org.apache.commons.math3.stat.descriptive.rank.Percentile for computational details.
The array is modified in-place. Do a F64Array.copy of the array
to avoid mutation if necessary.
q,
F64Array.copypublic static void shuffle(@NotNull
F64Array $receiver,
@NotNull
org.apache.commons.math3.random.RandomGenerator randomGenerator)
Randomly permutes the elements of this 1-D array.
See https://en.wikipedia.org/wiki/Fisher%E2%80%93Yates_shuffle.