time-to-botec

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

repl.txt (1541B)


      1 
      2 {{alias}}( x, k, λ )
      3     Evaluates the moment-generating function (MGF) for a Weibull distribution
      4     with shape parameter `k` and scale parameter `λ` at a value `t`.
      5 
      6     If provided `NaN` as any argument, the function returns `NaN`.
      7 
      8     If provided a non-positive value for `λ` or `k`, the function returns `NaN`.
      9 
     10     Parameters
     11     ----------
     12     x: number
     13         Input value.
     14 
     15     k: number
     16         Shape parameter.
     17 
     18     λ: number
     19         Scale parameter.
     20 
     21     Returns
     22     -------
     23     out: number
     24         Evaluated MGF.
     25 
     26     Examples
     27     --------
     28     > var y = {{alias}}( 1.0, 1.0, 0.5 )
     29     ~2.0
     30     > y = {{alias}}( -1.0, 4.0, 4.0 )
     31     ~0.019
     32 
     33     > y = {{alias}}( NaN, 1.0, 1.0 )
     34     NaN
     35     > y = {{alias}}( 0.0, NaN, 1.0 )
     36     NaN
     37     > y = {{alias}}( 0.0, 1.0, NaN )
     38     NaN
     39 
     40     > y = {{alias}}( 0.2, -1.0, 0.5 )
     41     NaN
     42     > y = {{alias}}( 0.2, 0.0, 0.5 )
     43     NaN
     44 
     45     > y = {{alias}}( 0.2, 0.5, -1.0 )
     46     NaN
     47     > y = {{alias}}( 0.2, 0.5, 0.0 )
     48     NaN
     49 
     50 
     51 {{alias}}.factory( k, λ )
     52     Returns a function for evaluating the moment-generating function (MGF) of a
     53     Weibull distribution with shape parameter `k` and scale parameter `λ`.
     54 
     55     Parameters
     56     ----------
     57     k: number
     58         Shape parameter.
     59 
     60     λ: number
     61         Scale parameter.
     62 
     63     Returns
     64     -------
     65     mgf: Function
     66         Moment-generating function (MGF).
     67 
     68     Examples
     69     --------
     70     > var myMGF = {{alias}}.factory( 8.0, 10.0 );
     71     > var y = myMGF( 0.8 )
     72     ~3150.149
     73     > y = myMGF( 0.08 )
     74     ~2.137
     75 
     76     See Also
     77     --------
     78