The distributions Reference Manual

This is the distributions Reference Manual, version 1.0.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 05:59:32 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 distributions

Random numbers and distributions

Long Name

Statistical distributions and related functions

Author

Steven Nunez <>

Home Page

https://lisp-stat.dev/docs/manuals/distributions/

Source Control

(GIT https://github.com/Lisp-Stat/distributions.git)

Bug Tracker

https://github.com/Lisp-Stat/distributions/issues

License

MS-PL

Long Description

The Distributions package provides a collection of probabilistic distributions and related functions including:

- Sampling from distributions
- Moments (e.g mean, variance, skewness, and kurtosis), entropy, and other properties
- Probability density/mass functions (pdf) and their logarithm (logpdf)
- Moment-generating functions and characteristic functions
- Maximum likelihood estimation
- Distribution composition and derived distributions

Version

1.0.0

Dependencies
  • alexandria (system).
  • anaphora (system).
  • array-operations (system).
  • cephes (system).
  • num-utils (system).
  • special-functions (system).
  • let-plus (system).
  • float-features (system).
Source

distributions.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 distributions/distributions.asd

Source

distributions.asd.

Parent Component

distributions (system).

ASDF Systems

distributions.


3.1.2 distributions/packages.lisp

Source

distributions.asd.

Parent Component

distributions (system).

Packages

3.1.3 distributions/internals.lisp

Dependency

packages.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface

3.1.4 distributions/generator.lisp

Dependency

internals.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.5 distributions/simple-multiplicative-congruential-generators.lisp

Dependency

generator.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.6 distributions/defs.lisp

Dependency

simple-multiplicative-congruential-generators.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.7 distributions/generics.lisp

Dependency

defs.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.8 distributions/discrete.lisp

Dependency

generics.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.9 distributions/uniform.lisp

Dependency

discrete.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.10 distributions/exponential.lisp

Dependency

uniform.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.11 distributions/normal.lisp

Dependency

exponential.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.12 distributions/log-normal.lisp

Dependency

normal.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.14 distributions/t-distribution.lisp

Dependency

truncated-normal.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.15 distributions/gamma.lisp

Dependency

t-distribution.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.16 distributions/chi-square.lisp

Dependency

gamma.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

s^2 (method).


3.1.17 distributions/beta.lisp

Dependency

chi-square.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.18 distributions/rayleigh.lisp

Dependency

beta.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.19 distributions/bernoulli.lisp

Dependency

rayleigh.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.20 distributions/binomial.lisp

Dependency

bernoulli.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.21 distributions/geometric.lisp

Dependency

binomial.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface
Internals

3.1.22 distributions/poisson.lisp

Dependency

geometric.lisp (file).

Source

distributions.asd.

Parent Component

distributions (system).

Public Interface

draw-poisson (function).


4 Packages

Packages are listed by definition order.


4.1 distributions

Source

packages.lisp.

Use List
  • alexandria.
  • anaphora.
  • common-lisp.
  • distributions.internals.
  • let-plus.
  • num-utils.elementwise.
  • num-utils.matrix.
  • num-utils.num=.
  • special-functions.
Public Interface
Internals

4.2 distributions.internals

Source

packages.lisp.

Use List
  • alexandria.
  • common-lisp.
  • let-plus.
Used By List

distributions.

Public Interface

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Macros

Macro: maybe-ignore-constant (ignore-constant? value constant)

Handle a constant that is calculated only when IGNORE-CONSTANT? is NIL and VALUE is not negative infinity (represented by NIL).

Package

distributions.internals.

Source

internals.lisp.

Macro: try ((&rest bindings) condition value)

Evaluate bindings (expanding into LET+, so all features can be used) until condition is satisfied, then return value.

Package

distributions.internals.

Source

internals.lisp.

Macro: with-floats ((&rest variables) &body body)

Rebind each variable, coerced to the internal float type used by DISTRIBUTIONS.

Package

distributions.internals.

Source

internals.lisp.


5.1.2 Ordinary functions

Function: as-float (x)

Return the argument coerced to the DISTRIBUTIONS library’s internal float type.

Package

distributions.internals.

Source

internals.lisp.

Function: as-float-probabilities (vector)

Normalize vector as probabilities, assert that all are positive, return them as a VECTOR-DOUBLE-FLOAT. Vector is always copied.

Package

distributions.internals.

Source

internals.lisp.

Function: as-float-vector (vector &key copy?)

Return VECTOR converted to another vector with elements converted to INTERNAL-FLOAT if necessary. When COPY?, the vector is always copied.

Package

distributions.internals.

Source

internals.lisp.

Function: cdf-gamma (x shape &key rate scale upper-tail log)

CDF of Gamma with parameterisation like that of R pgamma

Package

distributions.

Source

gamma.lisp.

Function: distinct-random-integers (count limit &key rng)

Return a vector of COUNT distinct random integers, in increasing order, drawn from the uniform discrete distribution on {0 , ..., limit-1}.

Package

distributions.

Source

discrete.lisp.

Function: distinct-random-integers-dense (count limit &key rng)

Implementation of DISTINCT-RANDOM-INTEGERS when count/limit is (relatively) high. Implements algorithm S from @cite{taocp3}, p 142.

Package

distributions.

Source

discrete.lisp.

Function: draw-bernoulli (p &key rng)

Return T with probability p, otherwise NIL. Rationals are handled exactly.

Package

distributions.

Source

bernoulli.lisp.

Function: draw-binomial (p n &key rng)

Return the number of successes out of N Bernoulli trials with probability of success P.

Package

distributions.

Source

binomial.lisp.

Function: draw-exponential (rate &key rng)

Return a random variable from the Exponential(rate) distribution which has density rate*exp(-rate*x) for x>=0 and 0 for x<0. rate > 0.

Package

distributions.

Source

exponential.lisp.

Function: draw-geometric (p &key rng)

Return the number of Bernoulli trials, with probability of success P, that were needed to reach the first success. This is >= 1.

Package

distributions.

Source

geometric.lisp.

Function: draw-poisson (lamda &key rng)

Return the number of events that occur with probability LAMDA. The algorithm is from Donald E. Knuth (1969). Seminumerical Algorithms. The Art of Computer Programming, Volume 2. Addison Wesley. WARNING: It’s simple but only linear in the return value K and is numerically unstable for large LAMDA.

Package

distributions.

Source

poisson.lisp.

Function: draw-rayleigh (scale &key rng)

Return a random variable from the Rayleigh(scale) distribution, where scale > 0 and density x * exp(-x^2 / (2 scale^2)) / scale^2 for x>=0 and 0 for x<0.

Package

distributions.

Source

rayleigh.lisp.

Function: draw-standard-exponential (&key rng)

Return a random variable from the Exponential(1) distribution, which has density exp(-x) for x>=0 and 0 for x<0.

Package

distributions.

Source

exponential.lisp.

Function: draw-standard-normal (&key rng)

Draw a random number from N(0,1).

Package

distributions.

Source

normal.lisp.

Function: draw-standard-t (nu &key rng)

Draw a standard T random variate, with NU degrees of freedom.

Package

distributions.

Source

t-distribution.lisp.

Function: draw-uniform (left right &key rng)

Return a random variable from the uniform distribution between LEFT and RIGHT. It’s type is the same as that of (- LEFT RIGHT).

Package

distributions.

Source

uniform.lisp.

Function: from-standard-normal (x mu sigma)

Scale x from standard normal.

Package

distributions.

Source

normal.lisp.

Function: make-generator (&key seed type)

Make a random number generator object. SEED can be any of NIL, T, an other generator, an integer, or any type of seed that a generator of type TYPE supports: - NIL: the generator’s STD-SEED is used;
- T: a random seed is used;
- a generator: a clone is returned;
- otherwise: SEED is used as depends on the generator.

Package

distributions.

Source

generator.lisp.

Function: next (limit &optional rng)

Generates a uniformly distributed pseudo-random number greater than or equal to zero and less than LIMIT. RNG, if supplied, is the random generator to use.

Package

distributions.

Source

generator.lisp.

Function: pdf (rv x &optional ignore-constant?)

Probability distribution function of RANDOM-VARIABLE at X. See LOG-PDF for the semantics of IGNORE-CONSTANT?.

Package

distributions.

Source

defs.lisp.

Function: pdf-gamma (x a b)

Return the probability density function of a gamma distribution with shape a>0, scale b>0 Returns: x^(a-1)*exp(-x/b)/gamma(a)/b^a, x>0

Package

distributions.

Source

gamma.lisp.

Function: r-bernoulli (pr)
Package

distributions.

Source

bernoulli.lisp.

Function: r-beta (alpha beta)
Package

distributions.

Source

beta.lisp.

Function: r-binomial (pr n)
Package

distributions.

Source

binomial.lisp.

Function: r-chi-square (nu)

Chi-square distribution with NU degrees of freedom.

Package

distributions.

Source

chi-square.lisp.

Function: r-discrete (probabilities)
Package

distributions.

Source

discrete.lisp.

Function: r-exponential (rate)
Package

distributions.

Source

exponential.lisp.

Function: r-gamma (alpha beta)
Package

distributions.

Source

gamma.lisp.

Function: r-geometric (pr)
Package

distributions.

Source

geometric.lisp.

Function: r-inverse-chi-square (nu &optional s^2)

Generalized inverse chi-square distribution. Reparametrized to INVERSE-GAMMA.

Package

distributions.

Source

chi-square.lisp.

Function: r-inverse-gamma (alpha beta)
Package

distributions.

Source

gamma.lisp.

Function: r-log-normal (log-mean log-sd)
Package

distributions.

Source

log-normal.lisp.

Function: r-normal (&optional mean variance)
Package

distributions.

Source

normal.lisp.

Function: r-rayleigh (scale)
Package

distributions.

Source

rayleigh.lisp.

Function: r-t (mean scale nu)
Package

distributions.

Source

t-distribution.lisp.

Function: r-truncated-normal (left right &optional mu sigma)

Truncated normal distribution. If LEFT or RIGHT is NIL, it corresponds to -/+ infinity.

Package

distributions.

Source

truncated-normal.lisp.

Function: r-uniform (left right)
Package

distributions.

Source

uniform.lisp.

Function: t-scale-to-variance-coefficient (nu)

Return the coefficient that multiplies the Sigma matrix or the squared scale to get the variance of a (multivariate) Student-T distribution. Also checks that nu > 2, ie the variance is defined.

Package

distributions.

Source

t-distribution.lisp.

Function: to-standard-normal (x mu sigma)

Scale x to standard normal.

Package

distributions.

Source

normal.lisp.


5.1.3 Generic functions

Generic Function: alpha (r-gamma0)
Package

distributions.

Methods
Method: alpha ((r-beta0 r-beta))
Source

beta.lisp.

Method: alpha ((r-inverse-gamma0 r-inverse-gamma))
Source

gamma.lisp.

Method: alpha ((r-gamma0 r-gamma))
Source

gamma.lisp.

Generic Function: beta (r-gamma0)
Package

distributions.

Methods
Method: beta ((r-beta0 r-beta))
Source

beta.lisp.

Method: beta ((r-inverse-gamma0 r-inverse-gamma))
Source

gamma.lisp.

Method: beta ((r-gamma0 r-gamma))
Source

gamma.lisp.

Generic Function: cdf (random-variable x)

Cumulative distribution function of RANDOM-VARIABLE at X.

Package

distributions.

Source

defs.lisp.

Methods
Method: cdf ((r-bernoulli0 r-bernoulli) x)
Source

bernoulli.lisp.

Method: cdf ((r-rayleigh0 r-rayleigh) x)
Source

rayleigh.lisp.

Method: cdf ((r-gamma0 r-gamma) x)
Source

gamma.lisp.

Method: cdf ((left-truncated-normal0 left-truncated-normal) x)
Source

truncated-normal.lisp.

Method: cdf ((r-log-normal0 r-log-normal) x)
Source

log-normal.lisp.

Method: cdf ((r-normal0 r-normal) x)
Source

normal.lisp.

Method: cdf ((r-exponential0 r-exponential) x)
Source

exponential.lisp.

Method: cdf ((r-uniform0 r-uniform) x)
Source

uniform.lisp.

Method: cdf ((instance r-discrete) i)
Source

discrete.lisp.

Generic Function: draw (random-variable &key rng &allow-other-keys)

Draw random variates. Can also be used on generators.

Package

distributions.

Source

defs.lisp.

Methods
Method: draw ((r-geometric0 r-geometric) &key rng)
Source

geometric.lisp.

Method: draw ((r-binomial0 r-binomial) &key rng)
Source

binomial.lisp.

Method: draw ((r-bernoulli0 r-bernoulli) &key rng)
Source

bernoulli.lisp.

Method: draw ((r-rayleigh0 r-rayleigh) &key rng)
Source

rayleigh.lisp.

Method: draw ((r-beta0 r-beta) &key rng)
Source

beta.lisp.

Method: draw ((r-inverse-gamma0 r-inverse-gamma) &key rng)
Source

gamma.lisp.

Method: draw ((r-gamma0 r-gamma) &key rng)
Source

gamma.lisp.

Method: draw ((r-t0 r-t) &key rng)
Source

t-distribution.lisp.

Method: draw ((left-truncated-normal0 left-truncated-normal) &key rng)
Source

truncated-normal.lisp.

Method: draw ((r-log-normal0 r-log-normal) &key rng)
Source

log-normal.lisp.

Method: draw ((r-normal0 r-normal) &key rng)
Source

normal.lisp.

Method: draw ((r-exponential0 r-exponential) &key rng)
Source

exponential.lisp.

Method: draw ((r-uniform0 r-uniform) &key rng)
Source

uniform.lisp.

Method: draw ((instance r-discrete) &key rng)
Source

discrete.lisp.

Method: draw ((function function) &key rng)
Generic Function: generator (random-variable &key rng)

Return a closure that returns random draws.

Package

distributions.

Source

defs.lisp.

Methods
Method: generator (random-variable &key rng)
Generic Function: left (r-uniform0)
Package

distributions.

Methods
Method: left ((r-uniform0 r-uniform))
Source

uniform.lisp.

Generic Function: log-pdf (random-variable x &optional ignore-constant?)

Log of probability distribution function of RANDOM-VARIABLE at X. NIL corresponds to log(-infinity). When IGNORE-CONSTANT?, the result may be shifted by an arbitrary real constant that does not change between calls of the same RANDOM-VARIABLE. This may save computation, and is useful for MCMC methods, etc.

Package

distributions.

Source

defs.lisp.

Methods
Method: log-pdf ((r-inverse-gamma0 r-inverse-gamma) x &optional ignore-constant?)
Source

gamma.lisp.

Method: log-pdf ((r-gamma0 r-gamma) x &optional ignore-constant?)
Source

gamma.lisp.

Method: log-pdf ((left-truncated-normal0 left-truncated-normal) x &optional ignore-constant?)
Source

truncated-normal.lisp.

Method: log-pdf ((r-log-normal0 r-log-normal) x &optional ignore-constant?)
Source

log-normal.lisp.

Method: log-pdf ((r-normal0 r-normal) x &optional ignore-constant?)
Source

normal.lisp.

Method: log-pdf ((r-exponential0 r-exponential) x &optional ignore-constant?)
Source

exponential.lisp.

Method: log-pdf ((r-uniform0 r-uniform) x &optional ignore-constant?)
Source

uniform.lisp.

Method: log-pdf ((instance r-discrete) i &optional ignore-constant?)
Source

discrete.lisp.

Generic Function: mean (random-variable)

Mean of random variable.

Package

distributions.

Source

defs.lisp.

Methods
Method: mean ((r-geometric0 r-geometric))
Source

geometric.lisp.

Method: mean ((r-binomial0 r-binomial))
Source

binomial.lisp.

Method: mean ((r-bernoulli0 r-bernoulli))
Source

bernoulli.lisp.

Method: mean ((r-rayleigh0 r-rayleigh))
Source

rayleigh.lisp.

Method: mean ((r-beta0 r-beta))
Source

beta.lisp.

Method: mean ((r-inverse-gamma0 r-inverse-gamma))
Source

gamma.lisp.

Method: mean ((r-gamma0 r-gamma))
Source

gamma.lisp.

Method: mean ((r-t0 r-t))
Source

t-distribution.lisp.

Method: mean ((left-truncated-normal0 left-truncated-normal))
Source

truncated-normal.lisp.

Method: mean ((r-log-normal0 r-log-normal))
Source

log-normal.lisp.

Method: mean ((r-normal0 r-normal))
Source

normal.lisp.

Method: mean ((r-exponential0 r-exponential))
Source

exponential.lisp.

Method: mean ((r-uniform0 r-uniform))
Source

uniform.lisp.

Method: mean ((instance r-discrete))
Source

discrete.lisp.

Generic Function: nu (distribution)

Return the degrees of freedom when applicable.

Package

distributions.

Source

generics.lisp.

Methods
Method: nu ((r-inverse-gamma r-inverse-gamma))
Source

chi-square.lisp.

Method: nu ((r-gamma r-gamma))
Source

chi-square.lisp.

Method: nu ((r-t0 r-t))
Source

t-distribution.lisp.

Generic Function: probabilities (instance)
Package

distributions.

Methods
Method: probabilities ((instance r-discrete))
Source

discrete.lisp.

Generic Function: quantile (random-variable q)

Quantile of RANDOM-VARIABLE at Q.

Package

distributions.

Source

generics.lisp.

Methods
Method: quantile ((r-beta0 r-beta) q)
Source

beta.lisp.

Method: quantile ((r-gamma0 r-gamma) q)
Source

gamma.lisp.

Method: quantile ((left-truncated-normal0 left-truncated-normal) q)
Source

truncated-normal.lisp.

Method: quantile ((r-log-normal0 r-log-normal) q)
Source

log-normal.lisp.

Method: quantile ((r-normal0 r-normal) q)
Source

normal.lisp.

Method: quantile ((r-exponential0 r-exponential) p)
Source

exponential.lisp.

Method: quantile ((r-uniform0 r-uniform) p)
Source

uniform.lisp.

Generic Function: rate (r-exponential0)
Package

distributions.

Methods
Method: rate ((r-exponential0 r-exponential))
Source

exponential.lisp.

Generic Function: right (r-uniform0)
Package

distributions.

Methods
Method: right ((r-uniform0 r-uniform))
Source

uniform.lisp.

Generic Function: scale (r-t0)
Package

distributions.

Methods
Method: scale ((r-rayleigh0 r-rayleigh))
Source

rayleigh.lisp.

Method: scale ((r-t0 r-t))
Source

t-distribution.lisp.

Generic Function: standard-deviation (random-variable)

Standard deviation of random variable.

Package

distributions.

Source

generics.lisp.

Methods
Method: standard-deviation ((random-variable r-univariate))
Generic Function: variance (random-variable)

Variance of random variable.

Package

distributions.

Source

defs.lisp.

Methods
Method: variance ((r-geometric0 r-geometric))
Source

geometric.lisp.

Method: variance ((r-binomial0 r-binomial))
Source

binomial.lisp.

Method: variance ((r-bernoulli0 r-bernoulli))
Source

bernoulli.lisp.

Method: variance ((r-rayleigh0 r-rayleigh))
Source

rayleigh.lisp.

Method: variance ((r-beta0 r-beta))
Source

beta.lisp.

Method: variance ((r-inverse-gamma0 r-inverse-gamma))
Source

gamma.lisp.

Method: variance ((r-gamma0 r-gamma))
Source

gamma.lisp.

Method: variance ((r-t0 r-t))
Source

t-distribution.lisp.

Method: variance ((left-truncated-normal0 left-truncated-normal))
Source

truncated-normal.lisp.

Method: variance ((r-log-normal0 r-log-normal))
Source

log-normal.lisp.

Method: variance ((r-normal0 r-normal))
Source

normal.lisp.

Method: variance ((r-exponential0 r-exponential))
Source

exponential.lisp.

Method: variance ((r-uniform0 r-uniform))
Source

uniform.lisp.

Method: variance ((instance r-discrete))
Source

discrete.lisp.


5.1.4 Standalone methods

Method: initialize-instance :after ((rng generator) &key seed &allow-other-keys)
Source

generator.lisp.

Method: initialize-instance :after ((self simple-multiplicative-congruential) &key &allow-other-keys)
Source

simple-multiplicative-congruential-generators.lisp.

Method: num= ((a1 r-inverse-gamma) (b2 r-inverse-gamma) &optional tolerance3)
Package

num-utils.num=.

Source

gamma.lisp.


5.1.5 Structures

Structure: r-bernoulli

Bernoulli(pr) distribution, with probability PR for success and 1-PR for failure.

Package

distributions.

Source

bernoulli.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: pr
Type

distributions.internals:internal-float

Readers

r-bernoulli-pr.

Writers

(setf r-bernoulli-pr).

Structure: r-beta

Beta(alpha,beta) distribution, with density proportional to x^(alpha-1)*(1-x)^(beta-1).

Package

distributions.

Source

beta.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: alpha
Type

distributions.internals:internal-float

Readers

r-beta-alpha.

Writers

(setf r-beta-alpha).

Slot: beta
Type

distributions.internals:internal-float

Readers

r-beta-beta.

Writers

(setf r-beta-beta).

Structure: r-binomial

Binomial(pr,n) distribution, with N Bernoulli trials with probability PR for success.

Package

distributions.

Source

binomial.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: pr
Type

distributions.internals:internal-float

Readers

r-binomial-pr.

Writers

(setf r-binomial-pr).

Slot: n
Type

integer

Readers

r-binomial-n.

Writers

(setf r-binomial-n).

Structure: r-discrete

Discrete probabilities.

Package

distributions.

Source

discrete.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: probabilities
Type

distributions.internals:float-vector

Readers

r-discrete-probabilities.

Writers

(setf r-discrete-probabilities).

Slot: prob
Type

distributions.internals:float-vector

Readers

r-discrete-prob.

Writers

(setf r-discrete-prob).

Slot: alias
Type

(simple-array fixnum (*))

Readers

r-discrete-alias.

Writers

(setf r-discrete-alias).

Slot: n-float
Type

distributions.internals:internal-float

Readers

r-discrete-n-float.

Writers

(setf r-discrete-n-float).

Structure: r-exponential

Exponential(rate) distribution, with density rate*exp(-rate*x) for x>=0 and 0 for x<0. rate > 0.

Package

distributions.

Source

exponential.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: rate
Type

distributions.internals:internal-float

Readers

r-exponential-rate.

Writers

(setf r-exponential-rate).

Structure: r-gamma

Gamma(alpha,beta) distribution, with density proportional to x^(alpha-1) exp(-x*beta). Alpha and beta are known as shape and inverse scale (or rate) parameters, respectively.

Package

distributions.

Source

gamma.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: alpha
Type

distributions.internals:internal-float

Readers

r-gamma-alpha.

Writers

(setf r-gamma-alpha).

Slot: beta
Type

distributions.internals:internal-float

Readers

r-gamma-beta.

Writers

(setf r-gamma-beta).

Structure: r-geometric

Geometric(pr) distribution.

Package

distributions.

Source

geometric.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: pr
Type

distributions.internals:internal-float

Readers

r-geometric-pr.

Writers

(setf r-geometric-pr).

Structure: r-inverse-gamma

Inverse-Gamma(alpha,beta) distribution, with density p(x) proportional to x^(-alpha+1) exp(-beta/x)

Package

distributions.

Source

gamma.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: alpha
Type

distributions.internals:internal-float

Readers

r-inverse-gamma-alpha.

Writers

(setf r-inverse-gamma-alpha).

Slot: beta
Type

distributions.internals:internal-float

Readers

r-inverse-gamma-beta.

Writers

(setf r-inverse-gamma-beta).

Structure: r-log-normal

Log-normal distribution with location log-mean and scale log-sd.

Package

distributions.

Source

log-normal.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: log-mean
Type

distributions.internals:internal-float

Readers

r-log-normal-log-mean.

Writers

(setf r-log-normal-log-mean).

Slot: log-sd
Type

distributions.internals:internal-float

Readers

r-log-normal-log-sd.

Writers

(setf r-log-normal-log-sd).

Structure: r-normal

Normal(mean,variance) distribution.

Package

distributions.

Source

normal.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: mean
Type

distributions.internals:internal-float

Readers

r-normal-mean.

Writers

(setf r-normal-mean).

Slot: sd
Type

distributions.internals:internal-float

Readers

r-normal-sd.

Writers

(setf r-normal-sd).

Structure: r-rayleigh

Rayleigh(scale) distribution with scale > 0 and density x * exp(-x^2 / (2 scale^2)) / scale^2 for x>=0 and 0 for x<0.

Package

distributions.

Source

rayleigh.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: scale
Type

distributions.internals:internal-float

Readers

r-rayleigh-scale.

Writers

(setf r-rayleigh-scale).

Structure: r-t

T(mean,scale,nu) random variate.

Package

distributions.

Source

t-distribution.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: mean
Type

distributions.internals:internal-float

Readers

r-t-mean.

Writers

(setf r-t-mean).

Slot: scale
Type

distributions.internals:internal-float

Readers

r-t-scale.

Writers

(setf r-t-scale).

Slot: nu
Type

distributions.internals:internal-float

Readers

r-t-nu.

Writers

(setf r-t-nu).

Structure: r-uniform

Uniform(left,right) distribution.

Package

distributions.

Source

uniform.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: left
Type

distributions.internals:internal-float

Readers

r-uniform-left.

Writers

(setf r-uniform-left).

Slot: right
Type

distributions.internals:internal-float

Readers

r-uniform-right.

Writers

(setf r-uniform-right).

Slot: width
Type

distributions.internals:internal-float

Readers

r-uniform-width.

Writers

(setf r-uniform-width).


5.1.6 Classes

Class: borosh13

Donald E. Knuth’s Borosh-Niederreiter, The Art of Computer Programming, Volume 2, Third Edition, Addison-Wesley, pp 106-108.

Package

distributions.

Source

simple-multiplicative-congruential-generators.lisp.

Direct superclasses

simple-multiplicative-congruential.

Direct slots
Slot: a
Initform

1812433253

Slot: chunk-length
Initform

32

Class: generator

Base class for random number generators.

Package

distributions.

Source

generator.lisp.

Direct subclasses

simple-multiplicative-congruential.

Direct methods
Direct slots
Slot: state

All information needed by the generator to create the next chunk of random bits. This state is modified after each call to NEXT-CHUNK.

Initargs

:state

Readers

state.

Writers

(setf state).

Slot: min

The minimum value return by NEXT-CHUNK.

Package

common-lisp.

Initargs

:min

Slot: max

The maximum value return by NEXT-CHUNK.

Package

common-lisp.

Initargs

:max

Slot: chunk-length

The length in bits of the integer returned by NEXT-CHUNK.

Readers

chunk-length.

Writers

This slot is read-only.

Slot: default-seed

The seed used by default, when the seed is NIL.

Initform

0

Readers

default-seed.

Writers

This slot is read-only.

Class: randu

The poor IBM randu generator. Park and Miller, Random Number
Generators: Good ones are hard to find, Communications of the ACM, October 1988, Volume 31, No 10, pp 1192-1201.

Package

distributions.

Source

simple-multiplicative-congruential-generators.lisp.

Direct superclasses

simple-multiplicative-congruential.

Direct slots
Slot: a
Initform

65539

Slot: chunk-length
Initform

31

Class: transputer

INMOS Transputer Development System generator.

Package

distributions.

Source

simple-multiplicative-congruential-generators.lisp.

Direct superclasses

simple-multiplicative-congruential.

Direct slots
Slot: a
Initform

1664525

Slot: chunk-length
Initform

32

Class: waterman14

Donald E. Knuth’s Waterman, The Art of Computer Programming, Volume 2, Third Edition, Addison-Wesley, pp 106-108.

Package

distributions.

Source

simple-multiplicative-congruential-generators.lisp.

Direct superclasses

simple-multiplicative-congruential.

Direct slots
Slot: a
Initform

1566083941

Slot: chunk-length
Initform

32


5.1.7 Types

Type: float-vector (&optional n)
Package

distributions.internals.

Source

internals.lisp.

Type: internal-float (&optional lower-limit upper-limit)

Type used for internal representation of floats in the DISTRIBUTIONS library.

Package

distributions.internals.

Source

internals.lisp.


5.2 Internals


5.2.1 Constants

Constant: +normal-log-pdf-constant+

Normalizing constant for a standard normal PDF.

Package

distributions.

Source

normal.lisp.


5.2.2 Special variables

Special Variable: *default-generator-type*
Package

distributions.

Source

generator.lisp.


5.2.3 Macros

Macro: define-rv (name constructor-lambda-list options slots constructor-form &rest methods)

Define a random variable, abstracting from the representation. Syntax:

NAME is a symbol, and will name the class and the creation function.

CONSTRUCTOR-LAMBDA-LIST will be used to wrap the CONSTRUCTOR-FORM, which can use the locally define macro (MAKE :slot-name value1 ...) to initialize slots.

SLOTS is a list of (slot-name &key type read-only reader) slot specifications. When READER is T, SLOT-NAME is used instead, otherwise a method is defined using the given symbol.

OPTIONS is (&key documentation instance), the default instance is a gensym.

METHODS are (function-name lambda-list &body body), with (INSTANCE NAME) prepended to the lambda-list, ie the instance is accessible using INSTANCE. Also, within BODY, slots are accessible by their names.

Package

distributions.

Source

defs.lisp.


5.2.4 Ordinary functions

Function: %next-double-float (limit rng)

Handle the single or double float case of RANDOM. We generate a float in [0d0, 1d0) by clobbering the mantissa of 1d0 with random bits (52 bits); this yields a number in [1d0, 2d0). Then 1d0 is subtracted.

Package

distributions.

Source

generator.lisp.

Function: %next-integer (limit rng)

Generates an integer greater than or equal to zero and less than LIMIT. Successive chunks are concatenated without overlap to construct integers larger than a single chunk. The return value has this property: If two integers are generated from the same RNG with LIMIT equal to 2^m and 2^n, respectively, then bit k is the same in both integers for 0 <= k < min(m,n). Each call to %NEXT-INTEGER consumes at least one chunk; bits left over from previous chunks are not re-used.

Package

distributions.

Source

generator.lisp.

Function: %next-single-float (limit rng)

Handle the single or double float case of RANDOM. We generate a float in [0f0, 1f0) by clobbering the mantissa of 1f0 with random bits (23 bits); this yields a number in [1f0, 2f0). Then 1f0 is subtracted.

Package

distributions.

Source

generator.lisp.

Function: cdf-gamma%+ (x k θ)

Return the cumulative gamma distribution function, shape k>0, scale θ>0

Package

distributions.

Source

gamma.lisp.

Function: cdf-normal% (x mu sigma)

Internal function for normal CDF.

Package

distributions.

Source

normal.lisp.

Function: check-probability (p &optional open)

Assert that P is a probability (ie a real number between 0 and 1). When OPEN is given, it is checked that p is not 0 (:LEFT), 1 (:RIGHT), or 0/1 (:BOTH).

Package

distributions.

Source

defs.lisp.

Function: copy-left-truncated-normal (instance)
Package

distributions.

Source

truncated-normal.lisp.

Function: copy-r-bernoulli (instance)
Package

distributions.

Source

bernoulli.lisp.

Function: copy-r-beta (instance)
Package

distributions.

Source

beta.lisp.

Function: copy-r-binomial (instance)
Package

distributions.

Source

binomial.lisp.

Function: copy-r-discrete (instance)
Package

distributions.

Source

discrete.lisp.

Function: copy-r-exponential (instance)
Package

distributions.

Source

exponential.lisp.

Function: copy-r-gamma (instance)
Package

distributions.

Source

gamma.lisp.

Function: copy-r-geometric (instance)
Package

distributions.

Source

geometric.lisp.

Function: copy-r-inverse-gamma (instance)
Package

distributions.

Source

gamma.lisp.

Function: copy-r-log-normal (instance)
Package

distributions.

Source

log-normal.lisp.

Function: copy-r-normal (instance)
Package

distributions.

Source

normal.lisp.

Function: copy-r-rayleigh (instance)
Package

distributions.

Source

rayleigh.lisp.

Function: copy-r-t (instance)
Package

distributions.

Source

t-distribution.lisp.

Function: copy-r-uniform (instance)
Package

distributions.

Source

uniform.lisp.

Function: copy-r-univariate (instance)
Package

distributions.

Source

generics.lisp.

Function: draw-bernoulli-bit (p &key rng)
Package

distributions.

Source

bernoulli.lisp.

Function: draw-left-truncated-standard-normal (left alpha &key rng)

Draw a left truncated standard normal, using an Exp(alpha,left) distribution. LEFT is the standardized boundary, ALPHA should be calculated with TRUNCATED-NORMAL-OPTIMAL-ALPHA.

Package

distributions.

Source

truncated-normal.lisp.

Function: draw-standard-gamma1 (alpha d c &key rng)

Return a standard gamma variate (beta=1) with shape parameter alpha >= 1. See Marsaglia and Tsang (2004). You should precalculate d and c using the utility function above.

Package

distributions.

Source

gamma.lisp.

Function: generate-seed ()

Return a 64-bit random seed, based on current time.

Package

distributions.

Source

generator.lisp.

Function: left-truncated-normal (mu sigma left)
Package

distributions.

Source

truncated-normal.lisp.

Reader: left-truncated-normal-alpha (instance)
Writer: (setf left-truncated-normal-alpha) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

alpha.

Reader: left-truncated-normal-left (instance)
Writer: (setf left-truncated-normal-left) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

left.

Reader: left-truncated-normal-left-standardized (instance)
Writer: (setf left-truncated-normal-left-standardized) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

left-standardized.

Reader: left-truncated-normal-m0 (instance)
Writer: (setf left-truncated-normal-m0) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

m0.

Reader: left-truncated-normal-mu (instance)
Writer: (setf left-truncated-normal-mu) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

mu.

Function: left-truncated-normal-p (object)
Package

distributions.

Source

truncated-normal.lisp.

Reader: left-truncated-normal-sigma (instance)
Writer: (setf left-truncated-normal-sigma) (instance)
Package

distributions.

Source

truncated-normal.lisp.

Target Slot

sigma.

Function: make-left-truncated-normal (&key mu sigma left left-standardized m0 alpha)
Package

distributions.

Source

truncated-normal.lisp.

Function: make-r-bernoulli (&key pr)
Package

distributions.

Source

bernoulli.lisp.

Function: make-r-beta (&key alpha beta)
Package

distributions.

Source

beta.lisp.

Function: make-r-binomial (&key pr n)
Package

distributions.

Source

binomial.lisp.

Function: make-r-discrete (&key probabilities prob alias n-float)
Package

distributions.

Source

discrete.lisp.

Function: make-r-exponential (&key rate)
Package

distributions.

Source

exponential.lisp.

Function: make-r-gamma (&key alpha beta)
Package

distributions.

Source

gamma.lisp.

Function: make-r-geometric (&key pr)
Package

distributions.

Source

geometric.lisp.

Function: make-r-inverse-gamma (&key alpha beta)
Package

distributions.

Source

gamma.lisp.

Function: make-r-log-normal (&key log-mean log-sd)
Package

distributions.

Source

log-normal.lisp.

Function: make-r-normal (&key mean sd)
Package

distributions.

Source

normal.lisp.

Function: make-r-rayleigh (&key scale)
Package

distributions.

Source

rayleigh.lisp.

Function: make-r-t (&key mean scale nu)
Package

distributions.

Source

t-distribution.lisp.

Function: make-r-uniform (&key left right width)
Package

distributions.

Source

uniform.lisp.

Function: make-r-univariate (&key)
Package

distributions.

Source

generics.lisp.

Function: pdf-gamma% (x shape scale)
Package

distributions.

Source

gamma.lisp.

Function: pdf-gamma* (x shape scale)
Package

distributions.

Source

gamma.lisp.

Function: pdf-gamma+ (x k θ)

Return the probability density function where:

K is the shape of the distribution
θ (theta) is the scale
X is the random variate

Package

distributions.

Source

gamma.lisp.

Function: pdf-normal% (x &key mu sigma)

Direct calculation of the Probability Density of the normal distribution.

Package

distributions.

Source

normal.lisp.

Function: quantile-normal% (q mu sigma)

Internal function for normal quantile.

Package

distributions.

Source

normal.lisp.

Function: r-bernoulli-p (object)
Package

distributions.

Source

bernoulli.lisp.

Reader: r-bernoulli-pr (instance)
Writer: (setf r-bernoulli-pr) (instance)
Package

distributions.

Source

bernoulli.lisp.

Target Slot

pr.

Reader: r-beta-alpha (instance)
Writer: (setf r-beta-alpha) (instance)
Package

distributions.

Source

beta.lisp.

Target Slot

alpha.

Reader: r-beta-beta (instance)
Writer: (setf r-beta-beta) (instance)
Package

distributions.

Source

beta.lisp.

Target Slot

beta.

Function: r-beta-p (object)
Package

distributions.

Source

beta.lisp.

Reader: r-binomial-n (instance)
Writer: (setf r-binomial-n) (instance)
Package

distributions.

Source

binomial.lisp.

Target Slot

n.

Function: r-binomial-p (object)
Package

distributions.

Source

binomial.lisp.

Reader: r-binomial-pr (instance)
Writer: (setf r-binomial-pr) (instance)
Package

distributions.

Source

binomial.lisp.

Target Slot

pr.

Reader: r-discrete-alias (instance)
Writer: (setf r-discrete-alias) (instance)
Package

distributions.

Source

discrete.lisp.

Target Slot

alias.

Reader: r-discrete-n-float (instance)
Writer: (setf r-discrete-n-float) (instance)
Package

distributions.

Source

discrete.lisp.

Target Slot

n-float.

Function: r-discrete-p (object)
Package

distributions.

Source

discrete.lisp.

Reader: r-discrete-prob (instance)
Writer: (setf r-discrete-prob) (instance)
Package

distributions.

Source

discrete.lisp.

Target Slot

prob.

Reader: r-discrete-probabilities (instance)
Writer: (setf r-discrete-probabilities) (instance)
Package

distributions.

Source

discrete.lisp.

Target Slot

probabilities.

Function: r-exponential-p (object)
Package

distributions.

Source

exponential.lisp.

Reader: r-exponential-rate (instance)
Writer: (setf r-exponential-rate) (instance)
Package

distributions.

Source

exponential.lisp.

Target Slot

rate.

Reader: r-gamma-alpha (instance)
Writer: (setf r-gamma-alpha) (instance)
Package

distributions.

Source

gamma.lisp.

Target Slot

alpha.

Reader: r-gamma-beta (instance)
Writer: (setf r-gamma-beta) (instance)
Package

distributions.

Source

gamma.lisp.

Target Slot

beta.

Function: r-gamma-p (object)
Package

distributions.

Source

gamma.lisp.

Function: r-geometric-p (object)
Package

distributions.

Source

geometric.lisp.

Reader: r-geometric-pr (instance)
Writer: (setf r-geometric-pr) (instance)
Package

distributions.

Source

geometric.lisp.

Target Slot

pr.

Reader: r-inverse-gamma-alpha (instance)
Writer: (setf r-inverse-gamma-alpha) (instance)
Package

distributions.

Source

gamma.lisp.

Target Slot

alpha.

Reader: r-inverse-gamma-beta (instance)
Writer: (setf r-inverse-gamma-beta) (instance)
Package

distributions.

Source

gamma.lisp.

Target Slot

beta.

Function: r-inverse-gamma-p (object)
Package

distributions.

Source

gamma.lisp.

Reader: r-log-normal-log-mean (instance)
Writer: (setf r-log-normal-log-mean) (instance)
Package

distributions.

Source

log-normal.lisp.

Target Slot

log-mean.

Reader: r-log-normal-log-sd (instance)
Writer: (setf r-log-normal-log-sd) (instance)
Package

distributions.

Source

log-normal.lisp.

Target Slot

log-sd.

Function: r-log-normal-p (object)
Package

distributions.

Source

log-normal.lisp.

Reader: r-normal-mean (instance)
Writer: (setf r-normal-mean) (instance)
Package

distributions.

Source

normal.lisp.

Target Slot

mean.

Function: r-normal-p (object)
Package

distributions.

Source

normal.lisp.

Reader: r-normal-sd (instance)
Writer: (setf r-normal-sd) (instance)
Package

distributions.

Source

normal.lisp.

Target Slot

sd.

Function: r-rayleigh-p (object)
Package

distributions.

Source

rayleigh.lisp.

Reader: r-rayleigh-scale (instance)
Writer: (setf r-rayleigh-scale) (instance)
Package

distributions.

Source

rayleigh.lisp.

Target Slot

scale.

Reader: r-t-mean (instance)
Writer: (setf r-t-mean) (instance)
Package

distributions.

Source

t-distribution.lisp.

Target Slot

mean.

Reader: r-t-nu (instance)
Writer: (setf r-t-nu) (instance)
Package

distributions.

Source

t-distribution.lisp.

Target Slot

nu.

Function: r-t-p (object)
Package

distributions.

Source

t-distribution.lisp.

Reader: r-t-scale (instance)
Writer: (setf r-t-scale) (instance)
Package

distributions.

Source

t-distribution.lisp.

Target Slot

scale.

Reader: r-uniform-left (instance)
Writer: (setf r-uniform-left) (instance)
Package

distributions.

Source

uniform.lisp.

Target Slot

left.

Function: r-uniform-p (object)
Package

distributions.

Source

uniform.lisp.

Reader: r-uniform-right (instance)
Writer: (setf r-uniform-right) (instance)
Package

distributions.

Source

uniform.lisp.

Target Slot

right.

Reader: r-uniform-width (instance)
Writer: (setf r-uniform-width) (instance)
Package

distributions.

Source

uniform.lisp.

Target Slot

width.

Function: r-univariate-p (object)
Package

distributions.

Source

generics.lisp.

Function: standard-gamma1-d-c (alpha)

Return precalculated constants (values d c), useful for drawing from a gamma distribution.

Package

distributions.

Source

gamma.lisp.

Function: truncated-normal-moments% (n mu sigma left right &optional m0)

N=0 gives the total mass of the truncated normal, used for normalization,
N=1 the mean, and N=2 the variance. where p(x) is the normal density. When LEFT or RIGHT are NIL, they are taken to be - or + infinity, respectively. M0 may be provided for efficiency if would be calculated multiple times. The formulas are from Jawitz (2004).

Package

distributions.

Source

truncated-normal.lisp.

Function: truncated-normal-optimal-alpha (left)

Calculate optimal exponential parameter for left-truncated normals. LEFT is the standardized boundary.

Package

distributions.

Source

truncated-normal.lisp.


5.2.5 Generic functions

Generic Reader: a (object)
Package

distributions.

Methods
Reader Method: a ((simple-multiplicative-congruential simple-multiplicative-congruential))

The multiplier of the sequence x(n+1) = A * x(n) mod M.

Source

simple-multiplicative-congruential-generators.lisp.

Target Slot

a.

Generic Reader: chunk-length (object)
Package

distributions.

Methods
Reader Method: chunk-length ((generator generator))

The length in bits of the integer returned by NEXT-CHUNK.

Source

generator.lisp.

Target Slot

chunk-length.

Generic Function: clone (self)
Package

distributions.

Methods
Method: clone ((self simple-multiplicative-congruential))
Source

simple-multiplicative-congruential-generators.lisp.

Generic Function: copy-state (rng)

Return a deep copy of RNG. The stream of random numbers drawn from RNG and its clone should be the same (given you draw according to the same distributions).

Package

distributions.

Source

generator.lisp.

Methods
Method: copy-state ((rng generator))
Method: copy-state ((rng random-state))
Generic Reader: default-seed (object)
Package

distributions.

Methods
Reader Method: default-seed ((generator generator))

The seed used by default, when the seed is NIL.

Source

generator.lisp.

Target Slot

default-seed.

Generic Function: generate-state (rng seed)

Return a state for a generator of RNG’s type using seed.

Package

distributions.

Source

generator.lisp.

Methods
Method: generate-state ((self simple-multiplicative-congruential) seed)
Source

simple-multiplicative-congruential-generators.lisp.

Method: generate-state ((rng generator) seed)
Generic Reader: m (object)
Package

distributions.

Methods
Reader Method: m ((simple-multiplicative-congruential simple-multiplicative-congruential))

The modulo of the sequence x(n+1) = A * x(n) mod M.

Source

simple-multiplicative-congruential-generators.lisp.

Target Slot

m.

Generic Function: n (r-binomial0)
Package

distributions.

Methods
Method: n ((r-binomial0 r-binomial))
Source

binomial.lisp.

Generic Function: next-chunk (self)
Package

distributions.

Methods
Method: next-chunk ((self simple-multiplicative-congruential))
Source

simple-multiplicative-congruential-generators.lisp.

Generic Function: next-real (self)
Package

distributions.

Methods
Method: next-real ((self simple-multiplicative-congruential))
Source

simple-multiplicative-congruential-generators.lisp.

Generic Function: pr (r-bernoulli0)
Package

distributions.

Methods
Method: pr ((r-geometric0 r-geometric))
Source

geometric.lisp.

Method: pr ((r-binomial0 r-binomial))
Source

binomial.lisp.

Method: pr ((r-bernoulli0 r-bernoulli))
Source

bernoulli.lisp.

Generic Function: s^2 (distribution)

Return the scale when applicable.

Package

distributions.

Source

generics.lisp.

Methods
Method: s^2 ((r-inverse-gamma r-inverse-gamma))
Source

chi-square.lisp.

Generic Function: sd (r-normal0)
Package

distributions.

Methods
Method: sd ((r-normal0 r-normal))
Source

normal.lisp.

Generic Reader: state (object)
Generic Writer: (setf state) (object)
Package

distributions.

Methods
Reader Method: state ((generator generator))
Writer Method: (setf state) ((generator generator))

All information needed by the generator to create the next chunk of random bits. This state is modified after each call to NEXT-CHUNK.

Source

generator.lisp.

Target Slot

state.


5.2.6 Structures

Structure: left-truncated-normal

Truncated normal distribution with given mu and sigma (corresponds to the mean and standard deviation in the untruncated case, respectively), on the interval [left, infinity).

Package

distributions.

Source

truncated-normal.lisp.

Direct superclasses

r-univariate.

Direct methods
Direct slots
Slot: mu
Type

distributions.internals:internal-float

Readers

left-truncated-normal-mu.

Writers

(setf left-truncated-normal-mu).

Slot: sigma
Type

distributions.internals:internal-float

Readers

left-truncated-normal-sigma.

Writers

(setf left-truncated-normal-sigma).

Slot: left
Type

distributions.internals:internal-float

Readers

left-truncated-normal-left.

Writers

(setf left-truncated-normal-left).

Slot: left-standardized
Type

distributions.internals:internal-float

Readers

left-truncated-normal-left-standardized.

Writers

(setf left-truncated-normal-left-standardized).

Slot: m0
Type

distributions.internals:internal-float

Readers

left-truncated-normal-m0.

Writers

(setf left-truncated-normal-m0).

Slot: alpha
Type

distributions.internals:internal-float

Readers

left-truncated-normal-alpha.

Writers

(setf left-truncated-normal-alpha).

Structure: r-univariate

Univariate distribution.

Package

distributions.

Source

generics.lisp.

Direct superclasses

structure-object.

Direct subclasses
Direct methods

standard-deviation.


5.2.7 Classes

Class: simple-multiplicative-congruential

A multiplicative congruential generator generates the sequence x(n+1) =
A * x(n) mod M and uses the seed as x(1). A simple multiplicative congruential generator is a multiplicative congruential generator with M a power of 2. This allows to implement the modulo operation as a bitwise and operation of M-1, which is also the maximum value of a random chunk.

Package

distributions.

Source

simple-multiplicative-congruential-generators.lisp.

Direct superclasses

generator.

Direct subclasses
Direct methods
Direct slots
Slot: default-seed
Initform

1

Slot: a

The multiplier of the sequence x(n+1) = A * x(n) mod M.

Readers

a.

Writers

This slot is read-only.

Slot: m

The modulo of the sequence x(n+1) = A * x(n) mod M.

Readers

m.

Writers

This slot is read-only.


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   %   (  
A   B   C   D   F   G   I   L   M   N   P   Q   R   S   T   V   W  
Index Entry  Section

%
%next-double-float: Private ordinary functions
%next-integer: Private ordinary functions
%next-single-float: Private ordinary functions

(
(setf left-truncated-normal-alpha): Private ordinary functions
(setf left-truncated-normal-left): Private ordinary functions
(setf left-truncated-normal-left-standardized): Private ordinary functions
(setf left-truncated-normal-m0): Private ordinary functions
(setf left-truncated-normal-mu): Private ordinary functions
(setf left-truncated-normal-sigma): Private ordinary functions
(setf r-bernoulli-pr): Private ordinary functions
(setf r-beta-alpha): Private ordinary functions
(setf r-beta-beta): Private ordinary functions
(setf r-binomial-n): Private ordinary functions
(setf r-binomial-pr): Private ordinary functions
(setf r-discrete-alias): Private ordinary functions
(setf r-discrete-n-float): Private ordinary functions
(setf r-discrete-prob): Private ordinary functions
(setf r-discrete-probabilities): Private ordinary functions
(setf r-exponential-rate): Private ordinary functions
(setf r-gamma-alpha): Private ordinary functions
(setf r-gamma-beta): Private ordinary functions
(setf r-geometric-pr): Private ordinary functions
(setf r-inverse-gamma-alpha): Private ordinary functions
(setf r-inverse-gamma-beta): Private ordinary functions
(setf r-log-normal-log-mean): Private ordinary functions
(setf r-log-normal-log-sd): Private ordinary functions
(setf r-normal-mean): Private ordinary functions
(setf r-normal-sd): Private ordinary functions
(setf r-rayleigh-scale): Private ordinary functions
(setf r-t-mean): Private ordinary functions
(setf r-t-nu): Private ordinary functions
(setf r-t-scale): Private ordinary functions
(setf r-uniform-left): Private ordinary functions
(setf r-uniform-right): Private ordinary functions
(setf r-uniform-width): Private ordinary functions
(setf state): Private generic functions
(setf state): Private generic functions

A
a: Private generic functions
a: Private generic functions
alpha: Public generic functions
alpha: Public generic functions
alpha: Public generic functions
alpha: Public generic functions
as-float: Public ordinary functions
as-float-probabilities: Public ordinary functions
as-float-vector: Public ordinary functions

B
beta: Public generic functions
beta: Public generic functions
beta: Public generic functions
beta: Public generic functions

C
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf: Public generic functions
cdf-gamma: Public ordinary functions
cdf-gamma%+: Private ordinary functions
cdf-normal%: Private ordinary functions
check-probability: Private ordinary functions
chunk-length: Private generic functions
chunk-length: Private generic functions
clone: Private generic functions
clone: Private generic functions
copy-left-truncated-normal: Private ordinary functions
copy-r-bernoulli: Private ordinary functions
copy-r-beta: Private ordinary functions
copy-r-binomial: Private ordinary functions
copy-r-discrete: Private ordinary functions
copy-r-exponential: Private ordinary functions
copy-r-gamma: Private ordinary functions
copy-r-geometric: Private ordinary functions
copy-r-inverse-gamma: Private ordinary functions
copy-r-log-normal: Private ordinary functions
copy-r-normal: Private ordinary functions
copy-r-rayleigh: Private ordinary functions
copy-r-t: Private ordinary functions
copy-r-uniform: Private ordinary functions
copy-r-univariate: Private ordinary functions
copy-state: Private generic functions
copy-state: Private generic functions
copy-state: Private generic functions

D
default-seed: Private generic functions
default-seed: Private generic functions
define-rv: Private macros
distinct-random-integers: Public ordinary functions
distinct-random-integers-dense: Public ordinary functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw: Public generic functions
draw-bernoulli: Public ordinary functions
draw-bernoulli-bit: Private ordinary functions
draw-binomial: Public ordinary functions
draw-exponential: Public ordinary functions
draw-geometric: Public ordinary functions
draw-left-truncated-standard-normal: Private ordinary functions
draw-poisson: Public ordinary functions
draw-rayleigh: Public ordinary functions
draw-standard-exponential: Public ordinary functions
draw-standard-gamma1: Private ordinary functions
draw-standard-normal: Public ordinary functions
draw-standard-t: Public ordinary functions
draw-uniform: Public ordinary functions

F
from-standard-normal: Public ordinary functions
Function, %next-double-float: Private ordinary functions
Function, %next-integer: Private ordinary functions
Function, %next-single-float: Private ordinary functions
Function, (setf left-truncated-normal-alpha): Private ordinary functions
Function, (setf left-truncated-normal-left): Private ordinary functions
Function, (setf left-truncated-normal-left-standardized): Private ordinary functions
Function, (setf left-truncated-normal-m0): Private ordinary functions
Function, (setf left-truncated-normal-mu): Private ordinary functions
Function, (setf left-truncated-normal-sigma): Private ordinary functions
Function, (setf r-bernoulli-pr): Private ordinary functions
Function, (setf r-beta-alpha): Private ordinary functions
Function, (setf r-beta-beta): Private ordinary functions
Function, (setf r-binomial-n): Private ordinary functions
Function, (setf r-binomial-pr): Private ordinary functions
Function, (setf r-discrete-alias): Private ordinary functions
Function, (setf r-discrete-n-float): Private ordinary functions
Function, (setf r-discrete-prob): Private ordinary functions
Function, (setf r-discrete-probabilities): Private ordinary functions
Function, (setf r-exponential-rate): Private ordinary functions
Function, (setf r-gamma-alpha): Private ordinary functions
Function, (setf r-gamma-beta): Private ordinary functions
Function, (setf r-geometric-pr): Private ordinary functions
Function, (setf r-inverse-gamma-alpha): Private ordinary functions
Function, (setf r-inverse-gamma-beta): Private ordinary functions
Function, (setf r-log-normal-log-mean): Private ordinary functions
Function, (setf r-log-normal-log-sd): Private ordinary functions
Function, (setf r-normal-mean): Private ordinary functions
Function, (setf r-normal-sd): Private ordinary functions
Function, (setf r-rayleigh-scale): Private ordinary functions
Function, (setf r-t-mean): Private ordinary functions
Function, (setf r-t-nu): Private ordinary functions
Function, (setf r-t-scale): Private ordinary functions
Function, (setf r-uniform-left): Private ordinary functions
Function, (setf r-uniform-right): Private ordinary functions
Function, (setf r-uniform-width): Private ordinary functions
Function, as-float: Public ordinary functions
Function, as-float-probabilities: Public ordinary functions
Function, as-float-vector: Public ordinary functions
Function, cdf-gamma: Public ordinary functions
Function, cdf-gamma%+: Private ordinary functions
Function, cdf-normal%: Private ordinary functions
Function, check-probability: Private ordinary functions
Function, copy-left-truncated-normal: Private ordinary functions
Function, copy-r-bernoulli: Private ordinary functions
Function, copy-r-beta: Private ordinary functions
Function, copy-r-binomial: Private ordinary functions
Function, copy-r-discrete: Private ordinary functions
Function, copy-r-exponential: Private ordinary functions
Function, copy-r-gamma: Private ordinary functions
Function, copy-r-geometric: Private ordinary functions
Function, copy-r-inverse-gamma: Private ordinary functions
Function, copy-r-log-normal: Private ordinary functions
Function, copy-r-normal: Private ordinary functions
Function, copy-r-rayleigh: Private ordinary functions
Function, copy-r-t: Private ordinary functions
Function, copy-r-uniform: Private ordinary functions
Function, copy-r-univariate: Private ordinary functions
Function, distinct-random-integers: Public ordinary functions
Function, distinct-random-integers-dense: Public ordinary functions
Function, draw-bernoulli: Public ordinary functions
Function, draw-bernoulli-bit: Private ordinary functions
Function, draw-binomial: Public ordinary functions
Function, draw-exponential: Public ordinary functions
Function, draw-geometric: Public ordinary functions
Function, draw-left-truncated-standard-normal: Private ordinary functions
Function, draw-poisson: Public ordinary functions
Function, draw-rayleigh: Public ordinary functions
Function, draw-standard-exponential: Public ordinary functions
Function, draw-standard-gamma1: Private ordinary functions
Function, draw-standard-normal: Public ordinary functions
Function, draw-standard-t: Public ordinary functions
Function, draw-uniform: Public ordinary functions
Function, from-standard-normal: Public ordinary functions
Function, generate-seed: Private ordinary functions
Function, left-truncated-normal: Private ordinary functions
Function, left-truncated-normal-alpha: Private ordinary functions
Function, left-truncated-normal-left: Private ordinary functions
Function, left-truncated-normal-left-standardized: Private ordinary functions
Function, left-truncated-normal-m0: Private ordinary functions
Function, left-truncated-normal-mu: Private ordinary functions
Function, left-truncated-normal-p: Private ordinary functions
Function, left-truncated-normal-sigma: Private ordinary functions
Function, make-generator: Public ordinary functions
Function, make-left-truncated-normal: Private ordinary functions
Function, make-r-bernoulli: Private ordinary functions
Function, make-r-beta: Private ordinary functions
Function, make-r-binomial: Private ordinary functions
Function, make-r-discrete: Private ordinary functions
Function, make-r-exponential: Private ordinary functions
Function, make-r-gamma: Private ordinary functions
Function, make-r-geometric: Private ordinary functions
Function, make-r-inverse-gamma: Private ordinary functions
Function, make-r-log-normal: Private ordinary functions
Function, make-r-normal: Private ordinary functions
Function, make-r-rayleigh: Private ordinary functions
Function, make-r-t: Private ordinary functions
Function, make-r-uniform: Private ordinary functions
Function, make-r-univariate: Private ordinary functions
Function, next: Public ordinary functions
Function, pdf: Public ordinary functions
Function, pdf-gamma: Public ordinary functions
Function, pdf-gamma%: Private ordinary functions
Function, pdf-gamma*: Private ordinary functions
Function, pdf-gamma+: Private ordinary functions
Function, pdf-normal%: Private ordinary functions
Function, quantile-normal%: Private ordinary functions
Function, r-bernoulli: Public ordinary functions
Function, r-bernoulli-p: Private ordinary functions
Function, r-bernoulli-pr: Private ordinary functions
Function, r-beta: Public ordinary functions
Function, r-beta-alpha: Private ordinary functions
Function, r-beta-beta: Private ordinary functions
Function, r-beta-p: Private ordinary functions
Function, r-binomial: Public ordinary functions
Function, r-binomial-n: Private ordinary functions
Function, r-binomial-p: Private ordinary functions
Function, r-binomial-pr: Private ordinary functions
Function, r-chi-square: Public ordinary functions
Function, r-discrete: Public ordinary functions
Function, r-discrete-alias: Private ordinary functions
Function, r-discrete-n-float: Private ordinary functions
Function, r-discrete-p: Private ordinary functions
Function, r-discrete-prob: Private ordinary functions
Function, r-discrete-probabilities: Private ordinary functions
Function, r-exponential: Public ordinary functions
Function, r-exponential-p: Private ordinary functions
Function, r-exponential-rate: Private ordinary functions
Function, r-gamma: Public ordinary functions
Function, r-gamma-alpha: Private ordinary functions
Function, r-gamma-beta: Private ordinary functions
Function, r-gamma-p: Private ordinary functions
Function, r-geometric: Public ordinary functions
Function, r-geometric-p: Private ordinary functions
Function, r-geometric-pr: Private ordinary functions
Function, r-inverse-chi-square: Public ordinary functions
Function, r-inverse-gamma: Public ordinary functions
Function, r-inverse-gamma-alpha: Private ordinary functions
Function, r-inverse-gamma-beta: Private ordinary functions
Function, r-inverse-gamma-p: Private ordinary functions
Function, r-log-normal: Public ordinary functions
Function, r-log-normal-log-mean: Private ordinary functions
Function, r-log-normal-log-sd: Private ordinary functions
Function, r-log-normal-p: Private ordinary functions
Function, r-normal: Public ordinary functions
Function, r-normal-mean: Private ordinary functions
Function, r-normal-p: Private ordinary functions
Function, r-normal-sd: Private ordinary functions
Function, r-rayleigh: Public ordinary functions
Function, r-rayleigh-p: Private ordinary functions
Function, r-rayleigh-scale: Private ordinary functions
Function, r-t: Public ordinary functions
Function, r-t-mean: Private ordinary functions
Function, r-t-nu: Private ordinary functions
Function, r-t-p: Private ordinary functions
Function, r-t-scale: Private ordinary functions
Function, r-truncated-normal: Public ordinary functions
Function, r-uniform: Public ordinary functions
Function, r-uniform-left: Private ordinary functions
Function, r-uniform-p: Private ordinary functions
Function, r-uniform-right: Private ordinary functions
Function, r-uniform-width: Private ordinary functions
Function, r-univariate-p: Private ordinary functions
Function, standard-gamma1-d-c: Private ordinary functions
Function, t-scale-to-variance-coefficient: Public ordinary functions
Function, to-standard-normal: Public ordinary functions
Function, truncated-normal-moments%: Private ordinary functions
Function, truncated-normal-optimal-alpha: Private ordinary functions

G
generate-seed: Private ordinary functions
generate-state: Private generic functions
generate-state: Private generic functions
generate-state: Private generic functions
generator: Public generic functions
generator: Public generic functions
Generic Function, (setf state): Private generic functions
Generic Function, a: Private generic functions
Generic Function, alpha: Public generic functions
Generic Function, beta: Public generic functions
Generic Function, cdf: Public generic functions
Generic Function, chunk-length: Private generic functions
Generic Function, clone: Private generic functions
Generic Function, copy-state: Private generic functions
Generic Function, default-seed: Private generic functions
Generic Function, draw: Public generic functions
Generic Function, generate-state: Private generic functions
Generic Function, generator: Public generic functions
Generic Function, left: Public generic functions
Generic Function, log-pdf: Public generic functions
Generic Function, m: Private generic functions
Generic Function, mean: Public generic functions
Generic Function, n: Private generic functions
Generic Function, next-chunk: Private generic functions
Generic Function, next-real: Private generic functions
Generic Function, nu: Public generic functions
Generic Function, pr: Private generic functions
Generic Function, probabilities: Public generic functions
Generic Function, quantile: Public generic functions
Generic Function, rate: Public generic functions
Generic Function, right: Public generic functions
Generic Function, scale: Public generic functions
Generic Function, sd: Private generic functions
Generic Function, standard-deviation: Public generic functions
Generic Function, state: Private generic functions
Generic Function, s^2: Private generic functions
Generic Function, variance: Public generic functions

I
initialize-instance: Public standalone methods
initialize-instance: Public standalone methods

L
left: Public generic functions
left: Public generic functions
left-truncated-normal: Private ordinary functions
left-truncated-normal-alpha: Private ordinary functions
left-truncated-normal-left: Private ordinary functions
left-truncated-normal-left-standardized: Private ordinary functions
left-truncated-normal-m0: Private ordinary functions
left-truncated-normal-mu: Private ordinary functions
left-truncated-normal-p: Private ordinary functions
left-truncated-normal-sigma: Private ordinary functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions
log-pdf: Public generic functions

M
m: Private generic functions
m: Private generic functions
Macro, define-rv: Private macros
Macro, maybe-ignore-constant: Public macros
Macro, try: Public macros
Macro, with-floats: Public macros
make-generator: Public ordinary functions
make-left-truncated-normal: Private ordinary functions
make-r-bernoulli: Private ordinary functions
make-r-beta: Private ordinary functions
make-r-binomial: Private ordinary functions
make-r-discrete: Private ordinary functions
make-r-exponential: Private ordinary functions
make-r-gamma: Private ordinary functions
make-r-geometric: Private ordinary functions
make-r-inverse-gamma: Private ordinary functions
make-r-log-normal: Private ordinary functions
make-r-normal: Private ordinary functions
make-r-rayleigh: Private ordinary functions
make-r-t: Private ordinary functions
make-r-uniform: Private ordinary functions
make-r-univariate: Private ordinary functions
maybe-ignore-constant: Public macros
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
mean: Public generic functions
Method, (setf state): Private generic functions
Method, a: Private generic functions
Method, alpha: Public generic functions
Method, alpha: Public generic functions
Method, alpha: Public generic functions
Method, beta: Public generic functions
Method, beta: Public generic functions
Method, beta: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, cdf: Public generic functions
Method, chunk-length: Private generic functions
Method, clone: Private generic functions
Method, copy-state: Private generic functions
Method, copy-state: Private generic functions
Method, default-seed: Private generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, draw: Public generic functions
Method, generate-state: Private generic functions
Method, generate-state: Private generic functions
Method, generator: Public generic functions
Method, initialize-instance: Public standalone methods
Method, initialize-instance: Public standalone methods
Method, left: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, log-pdf: Public generic functions
Method, m: Private generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, mean: Public generic functions
Method, n: Private generic functions
Method, next-chunk: Private generic functions
Method, next-real: Private generic functions
Method, nu: Public generic functions
Method, nu: Public generic functions
Method, nu: Public generic functions
Method, num=: Public standalone methods
Method, pr: Private generic functions
Method, pr: Private generic functions
Method, pr: Private generic functions
Method, probabilities: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, quantile: Public generic functions
Method, rate: Public generic functions
Method, right: Public generic functions
Method, scale: Public generic functions
Method, scale: Public generic functions
Method, sd: Private generic functions
Method, standard-deviation: Public generic functions
Method, state: Private generic functions
Method, s^2: Private generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions
Method, variance: Public generic functions

N
n: Private generic functions
n: Private generic functions
next: Public ordinary functions
next-chunk: Private generic functions
next-chunk: Private generic functions
next-real: Private generic functions
next-real: Private generic functions
nu: Public generic functions
nu: Public generic functions
nu: Public generic functions
nu: Public generic functions
num=: Public standalone methods

P
pdf: Public ordinary functions
pdf-gamma: Public ordinary functions
pdf-gamma%: Private ordinary functions
pdf-gamma*: Private ordinary functions
pdf-gamma+: Private ordinary functions
pdf-normal%: Private ordinary functions
pr: Private generic functions
pr: Private generic functions
pr: Private generic functions
pr: Private generic functions
probabilities: Public generic functions
probabilities: Public generic functions

Q
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile: Public generic functions
quantile-normal%: Private ordinary functions

R
r-bernoulli: Public ordinary functions
r-bernoulli-p: Private ordinary functions
r-bernoulli-pr: Private ordinary functions
r-beta: Public ordinary functions
r-beta-alpha: Private ordinary functions
r-beta-beta: Private ordinary functions
r-beta-p: Private ordinary functions
r-binomial: Public ordinary functions
r-binomial-n: Private ordinary functions
r-binomial-p: Private ordinary functions
r-binomial-pr: Private ordinary functions
r-chi-square: Public ordinary functions
r-discrete: Public ordinary functions
r-discrete-alias: Private ordinary functions
r-discrete-n-float: Private ordinary functions
r-discrete-p: Private ordinary functions
r-discrete-prob: Private ordinary functions
r-discrete-probabilities: Private ordinary functions
r-exponential: Public ordinary functions
r-exponential-p: Private ordinary functions
r-exponential-rate: Private ordinary functions
r-gamma: Public ordinary functions
r-gamma-alpha: Private ordinary functions
r-gamma-beta: Private ordinary functions
r-gamma-p: Private ordinary functions
r-geometric: Public ordinary functions
r-geometric-p: Private ordinary functions
r-geometric-pr: Private ordinary functions
r-inverse-chi-square: Public ordinary functions
r-inverse-gamma: Public ordinary functions
r-inverse-gamma-alpha: Private ordinary functions
r-inverse-gamma-beta: Private ordinary functions
r-inverse-gamma-p: Private ordinary functions
r-log-normal: Public ordinary functions
r-log-normal-log-mean: Private ordinary functions
r-log-normal-log-sd: Private ordinary functions
r-log-normal-p: Private ordinary functions
r-normal: Public ordinary functions
r-normal-mean: Private ordinary functions
r-normal-p: Private ordinary functions
r-normal-sd: Private ordinary functions
r-rayleigh: Public ordinary functions
r-rayleigh-p: Private ordinary functions
r-rayleigh-scale: Private ordinary functions
r-t: Public ordinary functions
r-t-mean: Private ordinary functions
r-t-nu: Private ordinary functions
r-t-p: Private ordinary functions
r-t-scale: Private ordinary functions
r-truncated-normal: Public ordinary functions
r-uniform: Public ordinary functions
r-uniform-left: Private ordinary functions
r-uniform-p: Private ordinary functions
r-uniform-right: Private ordinary functions
r-uniform-width: Private ordinary functions
r-univariate-p: Private ordinary functions
rate: Public generic functions
rate: Public generic functions
right: Public generic functions
right: Public generic functions

S
scale: Public generic functions
scale: Public generic functions
scale: Public generic functions
sd: Private generic functions
sd: Private generic functions
standard-deviation: Public generic functions
standard-deviation: Public generic functions
standard-gamma1-d-c: Private ordinary functions
state: Private generic functions
state: Private generic functions
s^2: Private generic functions
s^2: Private generic functions

T
t-scale-to-variance-coefficient: Public ordinary functions
to-standard-normal: Public ordinary functions
truncated-normal-moments%: Private ordinary functions
truncated-normal-optimal-alpha: Private ordinary functions
try: Public macros

V
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions
variance: Public generic functions

W
with-floats: Public macros


A.3 Variables

Jump to:   *   +  
A   B   C   D   L   M   N   P   R   S   W  
Index Entry  Section

*
*default-generator-type*: Private special variables

+
+normal-log-pdf-constant+: Private constants

A
a: Public classes
a: Public classes
a: Public classes
a: Public classes
a: Private classes
alias: Public structures
alpha: Public structures
alpha: Public structures
alpha: Public structures
alpha: Private structures

B
beta: Public structures
beta: Public structures
beta: Public structures

C
chunk-length: Public classes
chunk-length: Public classes
chunk-length: Public classes
chunk-length: Public classes
chunk-length: Public classes
Constant, +normal-log-pdf-constant+: Private constants

D
default-seed: Public classes
default-seed: Private classes

L
left: Public structures
left: Private structures
left-standardized: Private structures
log-mean: Public structures
log-sd: Public structures

M
m: Private classes
m0: Private structures
max: Public classes
mean: Public structures
mean: Public structures
min: Public classes
mu: Private structures

N
n: Public structures
n-float: Public structures
nu: Public structures

P
pr: Public structures
pr: Public structures
pr: Public structures
prob: Public structures
probabilities: Public structures

R
rate: Public structures
right: Public structures

S
scale: Public structures
scale: Public structures
sd: Public structures
sigma: Private structures
Slot, a: Public classes
Slot, a: Public classes
Slot, a: Public classes
Slot, a: Public classes
Slot, a: Private classes
Slot, alias: Public structures
Slot, alpha: Public structures
Slot, alpha: Public structures
Slot, alpha: Public structures
Slot, alpha: Private structures
Slot, beta: Public structures
Slot, beta: Public structures
Slot, beta: Public structures
Slot, chunk-length: Public classes
Slot, chunk-length: Public classes
Slot, chunk-length: Public classes
Slot, chunk-length: Public classes
Slot, chunk-length: Public classes
Slot, default-seed: Public classes
Slot, default-seed: Private classes
Slot, left: Public structures
Slot, left: Private structures
Slot, left-standardized: Private structures
Slot, log-mean: Public structures
Slot, log-sd: Public structures
Slot, m: Private classes
Slot, m0: Private structures
Slot, max: Public classes
Slot, mean: Public structures
Slot, mean: Public structures
Slot, min: Public classes
Slot, mu: Private structures
Slot, n: Public structures
Slot, n-float: Public structures
Slot, nu: Public structures
Slot, pr: Public structures
Slot, pr: Public structures
Slot, pr: Public structures
Slot, prob: Public structures
Slot, probabilities: Public structures
Slot, rate: Public structures
Slot, right: Public structures
Slot, scale: Public structures
Slot, scale: Public structures
Slot, sd: Public structures
Slot, sigma: Private structures
Slot, state: Public classes
Slot, width: Public structures
Special Variable, *default-generator-type*: Private special variables
state: Public classes

W
width: Public structures


A.4 Data types

Jump to:   B   C   D   E   F   G   I   L   N   P   R   S   T   U   W  
Index Entry  Section

B
bernoulli.lisp: The distributions/bernoulli․lisp file
beta.lisp: The distributions/beta․lisp file
binomial.lisp: The distributions/binomial․lisp file
borosh13: Public classes

C
chi-square.lisp: The distributions/chi-square․lisp file
Class, borosh13: Public classes
Class, generator: Public classes
Class, randu: Public classes
Class, simple-multiplicative-congruential: Private classes
Class, transputer: Public classes
Class, waterman14: Public classes

D
defs.lisp: The distributions/defs․lisp file
discrete.lisp: The distributions/discrete․lisp file
distributions: The distributions system
distributions: The distributions package
distributions.asd: The distributions/distributions․asd file
distributions.internals: The distributions․internals package

E
exponential.lisp: The distributions/exponential․lisp file

F
File, bernoulli.lisp: The distributions/bernoulli․lisp file
File, beta.lisp: The distributions/beta․lisp file
File, binomial.lisp: The distributions/binomial․lisp file
File, chi-square.lisp: The distributions/chi-square․lisp file
File, defs.lisp: The distributions/defs․lisp file
File, discrete.lisp: The distributions/discrete․lisp file
File, distributions.asd: The distributions/distributions․asd file
File, exponential.lisp: The distributions/exponential․lisp file
File, gamma.lisp: The distributions/gamma․lisp file
File, generator.lisp: The distributions/generator․lisp file
File, generics.lisp: The distributions/generics․lisp file
File, geometric.lisp: The distributions/geometric․lisp file
File, internals.lisp: The distributions/internals․lisp file
File, log-normal.lisp: The distributions/log-normal․lisp file
File, normal.lisp: The distributions/normal․lisp file
File, packages.lisp: The distributions/packages․lisp file
File, poisson.lisp: The distributions/poisson․lisp file
File, rayleigh.lisp: The distributions/rayleigh․lisp file
File, simple-multiplicative-congruential-generators.lisp: The distributions/simple-multiplicative-congruential-generators․lisp file
File, t-distribution.lisp: The distributions/t-distribution․lisp file
File, truncated-normal.lisp: The distributions/truncated-normal․lisp file
File, uniform.lisp: The distributions/uniform․lisp file
float-vector: Public types

G
gamma.lisp: The distributions/gamma․lisp file
generator: Public classes
generator.lisp: The distributions/generator․lisp file
generics.lisp: The distributions/generics․lisp file
geometric.lisp: The distributions/geometric․lisp file

I
internal-float: Public types
internals.lisp: The distributions/internals․lisp file

L
left-truncated-normal: Private structures
log-normal.lisp: The distributions/log-normal․lisp file

N
normal.lisp: The distributions/normal․lisp file

P
Package, distributions: The distributions package
Package, distributions.internals: The distributions․internals package
packages.lisp: The distributions/packages․lisp file
poisson.lisp: The distributions/poisson․lisp file

R
r-bernoulli: Public structures
r-beta: Public structures
r-binomial: Public structures
r-discrete: Public structures
r-exponential: Public structures
r-gamma: Public structures
r-geometric: Public structures
r-inverse-gamma: Public structures
r-log-normal: Public structures
r-normal: Public structures
r-rayleigh: Public structures
r-t: Public structures
r-uniform: Public structures
r-univariate: Private structures
randu: Public classes
rayleigh.lisp: The distributions/rayleigh․lisp file

S
simple-multiplicative-congruential: Private classes
simple-multiplicative-congruential-generators.lisp: The distributions/simple-multiplicative-congruential-generators․lisp file
Structure, left-truncated-normal: Private structures
Structure, r-bernoulli: Public structures
Structure, r-beta: Public structures
Structure, r-binomial: Public structures
Structure, r-discrete: Public structures
Structure, r-exponential: Public structures
Structure, r-gamma: Public structures
Structure, r-geometric: Public structures
Structure, r-inverse-gamma: Public structures
Structure, r-log-normal: Public structures
Structure, r-normal: Public structures
Structure, r-rayleigh: Public structures
Structure, r-t: Public structures
Structure, r-uniform: Public structures
Structure, r-univariate: Private structures
System, distributions: The distributions system

T
t-distribution.lisp: The distributions/t-distribution․lisp file
transputer: Public classes
truncated-normal.lisp: The distributions/truncated-normal․lisp file
Type, float-vector: Public types
Type, internal-float: Public types

U
uniform.lisp: The distributions/uniform․lisp file

W
waterman14: Public classes