estimator.nd.TUniform#
- class estimator.nd.TUniform(b, n=None)[source]#
TUniform distribution ∈
ZZ ∩ [-2**b, 2**b]
, endpoints inclusive. This distribution samples the two end-points with probability 1/2**(b+2) and the intermediate points with probability 1/2**(b+1).As an example, with b=0 this distribution samples ±1 each with probability 1/4 and 0 with probability 1/2.
EXAMPLE:
>>> from estimator import * >>> ND.TUniform(0) D(σ=0.71) >>> ND.TUniform(10) D(σ=591.21)
- __call__(**kwargs)#
Call self as a function.
Methods
__init__
(b[, n])resize
(new_n)Return an altered distribution having a dimension new_n.
support_size
([fraction])Compute the size of the support covering the probability given as fraction.
Attributes
The number of non-zero coefficients in this distribution
Whether the value of coefficients are bounded
Whether the density of the distribution is < 1/2.