time-to-botec

Benchmark sampling in different programming languages
Log | Files | Refs | README

repl.txt (2301B)


      1 
      2 {{alias}}( [p] )
      3     Returns a geometric distribution object.
      4 
      5     Parameters
      6     ----------
      7     p: number (optional)
      8         Success probability. Must be between `0` and `1`. Default: `0.5`.
      9 
     10     Returns
     11     -------
     12     geometric: Object
     13         Distribution instance.
     14 
     15     geometric.p: number
     16         Success probability. If set, the value must be between `0` and `1`.
     17 
     18     geometric.entropy: number
     19         Read-only property which returns the differential entropy.
     20 
     21     geometric.kurtosis: number
     22         Read-only property which returns the excess kurtosis.
     23 
     24     geometric.mean: number
     25         Read-only property which returns the expected value.
     26 
     27     geometric.median: number
     28         Read-only property which returns the median.
     29 
     30     geometric.mode: number
     31         Read-only property which returns the mode.
     32 
     33     geometric.skewness: number
     34         Read-only property which returns the skewness.
     35 
     36     geometric.stdev: number
     37         Read-only property which returns the standard deviation.
     38 
     39     geometric.variance: number
     40         Read-only property which returns the variance.
     41 
     42     geometric.cdf: Function
     43         Evaluates the cumulative distribution function (CDF).
     44 
     45     geometric.logcdf: Function
     46         Evaluates the natural logarithm of the cumulative distribution function
     47         (CDF).
     48 
     49     geometric.logpmf: Function
     50         Evaluates the natural logarithm of the probability mass function (PMF).
     51 
     52     geometric.mgf: Function
     53         Evaluates the moment-generating function (MGF).
     54 
     55     geometric.pmf: Function
     56         Evaluates the probability mass function (PMF).
     57 
     58     geometric.quantile: Function
     59         Evaluates the quantile function at probability `p`.
     60 
     61     Examples
     62     --------
     63     > var geometric = {{alias}}( 0.6 );
     64     > geometric.p
     65     0.6
     66     > geometric.entropy
     67     ~1.122
     68     > geometric.kurtosis
     69     ~6.9
     70     > geometric.mean
     71     ~0.667
     72     > geometric.median
     73     0.0
     74     > geometric.mode
     75     0.0
     76     > geometric.skewness
     77     ~2.214
     78     > geometric.stdev
     79     ~1.054
     80     > geometric.variance
     81     ~1.111
     82     > geometric.cdf( 3.0 )
     83     ~0.974
     84     > geometric.logcdf( 3.0 )
     85     ~-0.026
     86     > geometric.logpmf( 4.0 )
     87     ~-4.176
     88     > geometric.mgf( 0.5 )
     89     ~2.905
     90     > geometric.pmf( 2.0 )
     91     ~0.096
     92     > geometric.quantile( 0.7 )
     93     1.0
     94 
     95     See Also
     96     --------
     97