Class

ai.lum.common.RandomUtils

RandomWrapper

Related Doc: package RandomUtils

Permalink

implicit final class RandomWrapper extends AnyVal

Linear Supertypes
AnyVal, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. RandomWrapper
  2. AnyVal
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new RandomWrapper(random: Random)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def choice[A](xs: TraversableOnce[A]): A

    Permalink
  6. def choice[A](xs: Array[A]): A

    Permalink
  7. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  8. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  9. def nextBytes(count: Int): Array[Byte]

    Permalink

    Creates an array of random bytes.

  10. def nextDouble(startInclusive: Double, endInclusive: Double): Double

    Permalink

    Returns a random double within the specified range.

  11. def nextExponential(lambda: Double): Double

    Permalink

    Exponential distribution.

    Exponential distribution. lambda is 1.0 divided by the desired mean. It should be nonzero. Returned values range from 0 to positive infinity if lambda is positive, and from negative infinity to 0 if lambda is negative.

  12. def nextFloat(startInclusive: Float, endInclusive: Float): Float

    Permalink

    Returns a random float within the specified range.

  13. def nextGaussian(mu: Double, sigma: Double): Double

    Permalink

    Gaussian distribution.

    Gaussian distribution. mu is the mean, and sigma is the standard deviation.

  14. def nextInt(startInclusive: Int, endExclusive: Int): Int

    Permalink

    Returns a random integer within the specified range.

  15. def nextLogNormal(mu: Double, sigma: Double): Double

    Permalink

    Log normal distribution.

    Log normal distribution. If you take the natural logarithm of this distribution, you’ll get a normal distribution with mean mu and standard deviation sigma. mu can have any value, and sigma must be greater than zero.

  16. def nextLong(startInclusive: Long, endExclusive: Long): Long

    Permalink

    Returns a random long within the specified range.

  17. def nextNormal(mu: Double, sigma: Double): Double

    Permalink
  18. def nextPareto(alpha: Double): Double

    Permalink

    Pareto distribution.

    Pareto distribution. alpha is the shape parameter.

  19. def nextTriangular(low: Double, high: Double, mode: Double): Double

    Permalink

    Triangular distribution.

    Triangular distribution. Continuous distribution bounded by given lower and upper limits, and having a given mode value in-between.

  20. def nextWeibull(alpha: Double, beta: Double): Double

    Permalink

    Weibull distribution.

    Weibull distribution. alpha is the scale parameter and beta is the shape parameter.

  21. val random: Random

    Permalink
  22. def randomAlphabetic(count: Int): String

    Permalink
  23. def randomAlphanumeric(count: Int): String

    Permalink
  24. def randomAscii(count: Int): String

    Permalink
  25. def randomNumeric(count: Int): String

    Permalink
  26. def randomString(count: Int, chars: String): String

    Permalink
  27. def randomString(count: Int, chars: Array[Char]): String

    Permalink
  28. def randomString(count: Int): String

    Permalink
  29. def sample[A, CC[X] <: TraversableOnce[X]](xs: CC[A], k: Int, withReplacement: Boolean = false)(implicit cbf: CanBuildFrom[CC[A], A, CC[A]]): CC[A]

    Permalink
  30. def sample[A](xs: Array[A], k: Int, withReplacement: Boolean)(implicit arg0: ClassTag[A]): Array[A]

    Permalink
  31. def sample[A](xs: Array[A], k: Int)(implicit arg0: ClassTag[A]): Array[A]

    Permalink
  32. def shuffleArray[A](xs: Array[A])(implicit arg0: ClassTag[A]): Array[A]

    Permalink
  33. def toString(): String

    Permalink
    Definition Classes
    Any

Inherited from AnyVal

Inherited from Any

Ungrouped