Packages

  • package root
    Definition Classes
    root
  • package org
    Definition Classes
    root
  • package saddle

    Saddle is a Scala Data Library.

    Saddle

    Saddle is a Scala Data Library.

    Saddle provides array-backed, indexed one- and two-dimensional data structures.

    These data structures are specialized on JVM primitives. With them one can often avoid the overhead of boxing and unboxing.

    Basic operations also aim to be robust to missing values (NA's)

    The building blocks are intended to be easily composed.

    The foundational building blocks are:

    Inspiration for Saddle comes from many sources, including the R programming language, the pandas data analysis library for Python, and the Scala collections library.

    Definition Classes
    org
  • package spire
    Definition Classes
    saddle
  • package random
    Definition Classes
    spire
  • package rng
    Definition Classes
    random
  • Generator
  • GlobalRng

abstract class Generator extends AnyRef

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Generator
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new Generator()

Abstract Value Members

  1. abstract def copyInit: Generator
    Attributes
    protected[random]
  2. abstract def getSeedBytes(): Array[Byte]
  3. abstract def nextInt(): Int

    Generate an equally-distributed random Int.

  4. abstract def nextLong(): Long

    Generates a random long.

    Generates a random long. All 64-bit long values are equally likely.

  5. abstract def setSeedBytes(bytes: Array[Byte]): Unit

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def chooseFromArray[A](arr: Array[A])(implicit gen: Generator): A
  6. def chooseFromIterable[A](as: Iterable[A])(implicit gen: Generator): A
  7. def chooseFromSeq[A](seq: Seq[A])(implicit gen: Generator): A
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  9. def copy: Generator
  10. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  11. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  12. var extra: Boolean
    Attributes
    protected
  13. def fillBytes(arr: Array[Byte]): Unit

    Fill an array with random Bytes.

  14. def fillGaussians(arr: Array[Double], mean: Double, stddev: Double): Unit
  15. def fillGaussians(arr: Array[Double]): Unit
  16. def fillInts(arr: Array[Int]): Unit

    Fill an array with random Ints.

  17. def fillLongs(arr: Array[Long]): Unit

    Fill an array with random Longs.

  18. def fillShorts(arr: Array[Short]): Unit

    Fill an array with random Shorts.

  19. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  20. def generateBytes(n: Int): Array[Byte]

    Generate an array of n random Bytes.

  21. def generateGaussians(n: Int, mean: Double, stddev: Double): Array[Double]
  22. def generateGaussians(n: Int): Array[Double]
  23. def generateInts(n: Int): Array[Int]

    Generate an array of n random Ints.

  24. def generateLongs(n: Int): Array[Long]

    Generate an array of n random Longs.

  25. def generateShorts(n: Int): Array[Short]

    Generate an array of n random Shorts.

  26. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  27. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  28. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  29. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  30. def nextBits(n: Int): Int

    Generates a random integer using n bits of state (0 <= n <= 32).

  31. def nextBoolean(): Boolean

    Generates a random Boolean.

  32. def nextDouble(from: Double, until: Double): Double

    Generates a random double in [from, until).

  33. def nextDouble(n: Double): Double

    Generates a random double in [0.0, n).

  34. def nextDouble(): Double

    Generates a random double in [0.0, 1.0).

  35. def nextFloat(from: Float, until: Float): Float

    Generates a random float in [from, until).

  36. def nextFloat(n: Float): Float

    Generates a random float in [0.0, n).

  37. def nextFloat(): Float

    Generates a random float in [0.0, 1.0).

  38. def nextGaussian(mean: Double, stddev: Double): Double
  39. def nextGaussian(): Double
  40. def nextInt(from: Int, to: Int): Int

    Return an Int in [from, to].

  41. def nextInt(n: Int): Int

    Generates a random int between 0 (inclusive) and n (exclusive).

  42. def nextLong(from: Long, to: Long): Long

    Return an Long in [from, to].

  43. def nextLong(n: Long): Long

    Generates a random int between 0 (inclusive) and n (exclusive).

  44. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  45. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  46. def oneOf[A](as: A*): A

    Fill an Array[A] using the given Dist[A] instance.

  47. def sampleFromArray[A](as: Array[A], size: Int)(implicit arg0: ClassTag[A], gen: Generator): Array[A]
  48. def sampleFromTraversable[A](as: Iterable[A], size: Int)(implicit arg0: ClassTag[A], gen: Generator): Array[A]
  49. def shuffle[A](as: Array[A])(implicit gen: Generator): Unit
  50. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  51. def toString(): String
    Definition Classes
    AnyRef → Any
  52. var value: Double
    Attributes
    protected
  53. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  54. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  55. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from AnyRef

Inherited from Any

Ungrouped