repl.txt (1505B)
1 2 {{alias}}( x, μ, b ) 3 Evaluates the logarithm of the cumulative distribution function (CDF) for a 4 Laplace distribution with scale parameter `b` and location parameter `μ` at 5 a value `x`. 6 7 If provided `NaN` as any argument, the function returns `NaN`. 8 9 If provided `b <= 0`, the function returns `NaN`. 10 11 Parameters 12 ---------- 13 x: number 14 Input value. 15 16 μ: number 17 Location parameter. 18 19 b: number 20 Scale parameter. 21 22 Returns 23 ------- 24 out: number 25 Evaluated logCDF. 26 27 Examples 28 -------- 29 > var y = {{alias}}( 2.0, 0.0, 1.0 ) 30 ~-0.07 31 > y = {{alias}}( 5.0, 10.0, 3.0 ) 32 ~-2.36 33 > y = {{alias}}( NaN, 0.0, 1.0 ) 34 NaN 35 > y = {{alias}}( 2, NaN, 1.0 ) 36 NaN 37 > y = {{alias}}( 2.0, 0.0, NaN ) 38 NaN 39 // Negative scale parameter: 40 > y = {{alias}}( 2.0, 0.0, -1.0 ) 41 NaN 42 43 44 {{alias}}.factory( μ, b ) 45 Returns a function for evaluating the logarithm of the cumulative 46 distribution function (CDF) of a Laplace distribution with scale parameter 47 `b` and location parameter `μ`. 48 49 Parameters 50 ---------- 51 μ: number 52 Location parameter. 53 54 b: number 55 Scale parameter. 56 57 Returns 58 ------- 59 logcdf: Function 60 Logarithm of cumulative distribution function (CDF). 61 62 Examples 63 -------- 64 > var mylogcdf = {{alias}}.factory( 2.0, 3.0 ); 65 > var y = mylogcdf( 10.0 ) 66 ~-0.035 67 > y = mylogcdf( 2.0 ) 68 ~-0.693 69 70 See Also 71 -------- 72