Packages

trait Stochastic[+A] extends AnyRef

A random variable of concrete type A.

A

the concrete type of the random variable

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

Abstract Value Members

  1. abstract def sample: A

    Returns a sample from the random variable.

    Returns a sample from the random variable.

    returns

    a sample from the random variable

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 clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. def filter(f: (A) ⇒ Boolean): Stochastic[A]

    Creates a new random variable by filtering the values of the underlying random variable.

    Creates a new random variable by filtering the values of the underlying random variable. This implements rejection sampling. Same as withFilter.

    f

    the filter function

    returns

    a random variable

  9. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. def flatMap[B](f: (A) ⇒ Stochastic[B]): Stochastic[B]

    Creates a new random variable by applying a stochastic function to the underlying random variable.

    Creates a new random variable by applying a stochastic function to the underlying random variable. A sample from the new random variable is a sample from the random variable created by applying f to a sample of the underlying random variable.

    B

    the concrete type of the output of stochastic function f and of the new random variable

    f

    the stochastic function to apply

    returns

    a random variable

  11. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
  12. def hashCode(): Int
    Definition Classes
    AnyRef → Any
  13. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  14. def map[B](f: (A) ⇒ B): Stochastic[B]

    Creates a new random variable by applying a deterministic function to the underlying random variable.

    Creates a new random variable by applying a deterministic function to the underlying random variable. Samples from the new random variable will be samples from the underlying one to which function f is applied.

    B

    the output type of function f and the concrete type of the new random variable

    f

    the deterministic function to apply

    returns

    a random variable

  15. def markov[B >: A](f: (B) ⇒ Stochastic[B]): Stochastic[Stream[B]]

    Creates a new random variable which represents a Markov chain of the first order.

    Creates a new random variable which represents a Markov chain of the first order. The relationship between two consecutive terms in the chain is defined by the stochastic function f.

    B

    the type of the next term (mainly for covariance)

    f

    the distribution of the next term given the previous one

    returns

    a random variable in the space of infinite sequences of B.

  16. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. final def notify(): Unit
    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit
    Definition Classes
    AnyRef
  19. def repeat[B >: A, F[_]](f: (⇒ B) ⇒ F[B]): Stochastic[F[B]]

    Creates a new random variable which is a collection or any higher-kinded type of independent and identically distributed copies of the underlying random variable.

    Creates a new random variable which is a collection or any higher-kinded type of independent and identically distributed copies of the underlying random variable. This can be used to create Lists or even Streams of random variables.

    B

    the type of the new random variable (mainly for covariance)

    F

    the type of the collection or higher-kinded type

    f

    the function that performs the lifting

    returns

    a random variable

  20. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  21. def toString(): String
    Definition Classes
    AnyRef → Any
  22. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. def withFilter(f: (A) ⇒ Boolean): Stochastic[A]

    Creates a new random variable by filtering the values of the underlying random variable.

    Creates a new random variable by filtering the values of the underlying random variable. This implements rejection sampling. Same as filter, but needed for for-comprehensions.

    f

    the filter function

    returns

    a random variable

Inherited from AnyRef

Inherited from Any

Ungrouped