diff --git a/lib/node_modules/@stdlib/_tools/github/create-token/lib/request.js b/lib/node_modules/@stdlib/_tools/github/create-token/lib/request.js index b1d29495f1b7..c19fc160c8a6 100644 --- a/lib/node_modules/@stdlib/_tools/github/create-token/lib/request.js +++ b/lib/node_modules/@stdlib/_tools/github/create-token/lib/request.js @@ -115,7 +115,7 @@ function request( opts, data, clbk ) { body += chunk; } /** - * Event listener invoked upon a response end. + * Event listener invoked upon a response end. * * @private * @returns {void} diff --git a/lib/node_modules/@stdlib/_tools/remark/plugins/remark-svg-equations/lib/transformer.js b/lib/node_modules/@stdlib/_tools/remark/plugins/remark-svg-equations/lib/transformer.js index e01d7616d51e..a6c369363f04 100644 --- a/lib/node_modules/@stdlib/_tools/remark/plugins/remark-svg-equations/lib/transformer.js +++ b/lib/node_modules/@stdlib/_tools/remark/plugins/remark-svg-equations/lib/transformer.js @@ -169,8 +169,8 @@ function transformer( tree, file, clbk ) { * * *
- * Triangular root formula. - *
+ * Triangular root formula. + *
*
* * @@ -191,8 +191,8 @@ function transformer( tree, file, clbk ) { * \`\`\` * * * * diff --git a/lib/node_modules/@stdlib/array/base/take-map/lib/index.js b/lib/node_modules/@stdlib/array/base/take-map/lib/index.js index b3918c07e909..43784039ddf6 100644 --- a/lib/node_modules/@stdlib/array/base/take-map/lib/index.js +++ b/lib/node_modules/@stdlib/array/base/take-map/lib/index.js @@ -29,8 +29,8 @@ * var x = [ 1, 2, 3, 4 ]; * * function mapFunction( val ) { - return val; -} +* return val; +* } * * var indices = [ 0, 0, 1, 1, 3, 3 ]; * var y = takeMap( x, indices, 'throw', mapFunction ); @@ -45,8 +45,8 @@ * var indices = [ 0, 0, 1, 1, 3, 3 ]; * * function clbk( val ) { - return val; -} +* return val; +* } * * var arr = takeMap.assign( x, indices, 'throw', out, 1, 0, mapFunction ); * // returns [ 1, 1, 2, 2, 4, 4 ] diff --git a/lib/node_modules/@stdlib/math/base/special/csch/lib/index.js b/lib/node_modules/@stdlib/math/base/special/csch/lib/index.js index de576396216f..bd497c72625e 100644 --- a/lib/node_modules/@stdlib/math/base/special/csch/lib/index.js +++ b/lib/node_modules/@stdlib/math/base/special/csch/lib/index.js @@ -25,18 +25,18 @@ * * @example * var csch = require( '@stdlib/math/base/special/csch' ); - * - * var v = csch( 0.0 ); - * // returns Infinity - * - * v = csch( 2.0 ); - * // returns ~0.2757 - * - * v = csch( -2.0 ); - * // returns ~-0.2757 - * - * v = csch( NaN ); - * // returns NaN +* +* var v = csch( 0.0 ); +* // returns Infinity +* +* v = csch( 2.0 ); +* // returns ~0.2757 +* +* v = csch( -2.0 ); +* // returns ~-0.2757 +* +* v = csch( NaN ); +* // returns NaN */ // MODULES // diff --git a/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp.js b/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp.js index eab30b12de8e..993a32082a09 100644 --- a/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp.js +++ b/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp.js @@ -42,8 +42,7 @@ var reDecimalNumber = require( './main.js' ); * - `[0-9]+` * - match the characters `[0-9]` one or more times * -* - @constant +* @constant * @type {RegExp} * @default /[-+]{0,1}[0-9]*\.[0-9]+/ */ diff --git a/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp_capture.js b/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp_capture.js index 826a3f63407f..2b0bc5efff5d 100644 --- a/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp_capture.js +++ b/lib/node_modules/@stdlib/regexp/decimal-number/lib/regexp_capture.js @@ -45,8 +45,7 @@ var reDecimalNumber = require( './main.js' ); * - `[0-9]+` * - match the characters `[0-9]` one or more times * -* - @constant +* @constant * @type {RegExp} * @default /([-+]{0,1}[0-9]*\.[0-9]+)/ */ diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/cdf/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/cdf/README.md index af2ab00da7f8..9eff481878d6 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/cdf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/cdf/README.md @@ -109,7 +109,7 @@ y = cdf( 2.0, 0.5, 0.0 ); #### cdf.factory( d1, d2 ) -Returns a function for evaluating the [cumulative distribution function][cdf] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns a function for evaluating the [cumulative distribution function][cdf] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var mycdf = cdf.factory( 10.0, 2.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/entropy/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/entropy/README.md index 402d50d8b4ce..51965a5728af 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/entropy/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/entropy/README.md @@ -59,7 +59,7 @@ var entropy = require( '@stdlib/stats/base/dists/f/entropy' ); #### entropy( d1, d2 ) -Returns the [differential entropy][entropy] of a [F][f-distribution] distribution with numerator degrees of freedom `d1` and denominator degrees of freedom `d2` (in [nats][nats]). +Returns the [differential entropy][entropy] of an [F][f-distribution] distribution with numerator degrees of freedom `d1` and denominator degrees of freedom `d2` (in [nats][nats]). ```javascript var v = entropy( 4.0, 7.0 ); @@ -172,7 +172,7 @@ for ( i = 0; i < 10; i++ ) { #### stdlib_base_dists_f_entropy( d1, d2 ) -Evaluates the [differential entropy][entropy] of a [F][f-distribution] distribution with numerator degrees of freedom `d1` and denominator degrees of freedom `d2` (in [nats][nats]). +Evaluates the [differential entropy][entropy] of an [F][f-distribution] distribution with numerator degrees of freedom `d1` and denominator degrees of freedom `d2` (in [nats][nats]). ```c double out = stdlib_base_dists_f_entropy( 3.0, 7.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/mean/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/mean/README.md index 277eda9712ef..c4e430f5e919 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/mean/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/mean/README.md @@ -57,7 +57,7 @@ var mean = require( '@stdlib/stats/base/dists/f/mean' ); #### mean( d1, d2 ) -Returns the [expected value][expected-value] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns the [expected value][expected-value] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var v = mean( 4.0, 5.0 ); @@ -170,7 +170,7 @@ for ( i = 0; i < 10; i++ ) { #### stdlib_base_dists_f_mean( d1, d2 ) -Evaluates the [expected value][expected-value] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Evaluates the [expected value][expected-value] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```c double out = stdlib_base_dists_f_mean( 3.0, 5.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/mode/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/mode/README.md index 7909bd8abf94..2247088f6a82 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/mode/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/mode/README.md @@ -59,7 +59,7 @@ var mode = require( '@stdlib/stats/base/dists/f/mode' ); #### mode( d1, d2 ) -Returns the [mode][mode] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns the [mode][mode] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var v = mode( 4.0, 5.0 ); @@ -172,7 +172,7 @@ for ( i = 0; i < 10; i++ ) { #### stdlib_base_dists_f_mode( d1, d2 ) -Evaluates the [mode][mode] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Evaluates the [mode][mode] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```c double out = stdlib_base_dists_f_mode( 3.0, 5.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/pdf/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/pdf/README.md index 75fc41a63ff6..ca2615cdcfbd 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/pdf/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/pdf/README.md @@ -103,7 +103,7 @@ y = pdf( 2.0, 1.0, -1.0 ); #### pdf.factory( d1, d2 ) -Returns a `function` for evaluating the [PDF][pdf] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns a `function` for evaluating the [PDF][pdf] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var mypdf = pdf.factory( 6.0, 7.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/quantile/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/quantile/README.md index 6951175a5652..7cb292297661 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/quantile/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/quantile/README.md @@ -113,7 +113,7 @@ y = quantile( 0.4, 1.0, 0.0 ); #### quantile.factory( d1, d2 ) -Returns a function for evaluating the quantile function of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns a function for evaluating the quantile function of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var myquantile = quantile.factory( 10.0, 2.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/skewness/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/skewness/README.md index da6f5587eea3..f0546857105e 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/skewness/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/skewness/README.md @@ -59,7 +59,7 @@ var skewness = require( '@stdlib/stats/base/dists/f/skewness' ); #### skewness( d1, d2 ) -Returns the [skewness][skewness] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns the [skewness][skewness] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var v = skewness( 4.0, 7.0 ); @@ -175,7 +175,7 @@ for ( i = 0; i < 10; i++ ) { #### stdlib_base_dists_f_skewness( d1, d2 ) -Evaluates the [skewness][skewness] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Evaluates the [skewness][skewness] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```c double out = stdlib_base_dists_f_skewness( 3.0, 7.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/stdev/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/stdev/README.md index 69768ceda960..3d883d100ac4 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/stdev/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/stdev/README.md @@ -59,7 +59,7 @@ var stdev = require( '@stdlib/stats/base/dists/f/stdev' ); #### stdev( d1, d2 ) -Returns the [standard deviation][standard-deviation] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns the [standard deviation][standard-deviation] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var v = stdev( 4.0, 5.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/f/variance/README.md b/lib/node_modules/@stdlib/stats/base/dists/f/variance/README.md index ed74273720ca..ed59ef81232c 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/f/variance/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/f/variance/README.md @@ -59,7 +59,7 @@ var variance = require( '@stdlib/stats/base/dists/f/variance' ); #### variance( d1, d2 ) -Returns the [variance][variance] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Returns the [variance][variance] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```javascript var v = variance( 4.0, 5.0 ); @@ -172,7 +172,7 @@ for ( i = 0; i < 10; i++ ) { #### stdlib_base_dists_f_variance( d1, d2 ) -Evaluates the [variance][variance] of a [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). +Evaluates the [variance][variance] of an [F][f-distribution] distribution with parameters `d1` (numerator degrees of freedom) and `d2` (denominator degrees of freedom). ```c double out = stdlib_base_dists_f_variance( 3.0, 5.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/normal/stdev/README.md b/lib/node_modules/@stdlib/stats/base/dists/normal/stdev/README.md index d2fa4a1e6f38..c624fd683dd0 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/normal/stdev/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/normal/stdev/README.md @@ -200,6 +200,14 @@ int main( void ) { + + +
+ +
+ + + - - - -
- -
- - diff --git a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/README.md b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/README.md index 7438f675d5ac..e294590d2a2c 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/README.md +++ b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/README.md @@ -223,8 +223,8 @@ int main( void ) { for ( i = 0; i < 25; i++ ) { a = random_uniform( 0.0, 10.0 ); - b = random_uniform( 0.0, 10.0 ) + a; - c = a + (b - a) * random_uniform( 0.0, 1.0 ); // mode between a and b + b = random_uniform( a, 10.0 + a ); + c = random_uniform( a, b ); // mode between a and b y = stdlib_base_dists_triangular_mean( a, b, c ); printf( "a: %lf, b: %lf, c: %lf, E(X;a,b,c): %lf\n", a, b, c, y ); } diff --git a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/benchmark/c/benchmark.c b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/benchmark/c/benchmark.c index 44921d25a844..44de7c03ec27 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/benchmark/c/benchmark.c +++ b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/benchmark/c/benchmark.c @@ -75,13 +75,15 @@ static double tic( void ) { } /** -* Generates a random number on the interval [0,20). +* Generates a random number on the interval [min,max). * -* @return random number +* @param min minimum value (inclusive) +* @param max maximum value (exclusive) +* @return random number */ -static double rand_double( void ) { - int r = rand(); - return 20.0*(double)r / ( (double)RAND_MAX + 1.0 ); +static double random_uniform( const double min, const double max ) { + double v = (double)rand() / ( (double)RAND_MAX + 1.0 ); + return min + ( v*(max-min) ); } /** @@ -96,11 +98,11 @@ static double benchmark( void ) { double t; int i; - // Generate random parameters for the triangular distribution + // Generate random parameters for the triangular distribution: for ( i = 0; i < 100; i++ ) { - a[ i ] = rand_double() * 20.0; // Lower bound - b[ i ] = ( rand_double() * 20.0 ) + a[ i ]; // Upper bound - c[ i ] = ( rand_double() * ( b[i] - a[i] ) ) + a[i]; // Mode + a[ i ] = random_uniform( 0.0, 20.0 ); // Lower bound + b[ i ] = random_uniform( a[i], a[i]+20.0 ); // Upper bound + c[ i ] = random_uniform( a[i], b[i] ); // Mode } t = tic(); diff --git a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/examples/c/example.c b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/examples/c/example.c index 855158da5d37..353aff4ddf4c 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/examples/c/example.c +++ b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/examples/c/example.c @@ -34,8 +34,8 @@ int main( void ) { for ( i = 0; i < 25; i++ ) { a = random_uniform( 0.0, 10.0 ); - b = random_uniform( 0.0, 10.0 ) + a; - c = a + (b - a) * random_uniform( 0.0, 1.0 ); // mode between a and b + b = random_uniform( a, a+10.0 ); + c = random_uniform( a, b ); // mode between a and b y = stdlib_base_dists_triangular_mean( a, b, c ); printf( "a: %lf, b: %lf, c: %lf, E(X;a,b,c): %lf\n", a, b, c, y ); } diff --git a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/lib/native.js b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/lib/native.js index 2d7c2a6bad8b..46c4325647b3 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/lib/native.js +++ b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/lib/native.js @@ -40,7 +40,7 @@ var addon = require( './../src/addon.node' ); * * @example * var v = mean( 2.0, 8.0, 4.0 ); -* // returns 4.666666666666667 +* // returns ~4.667 * * @example * var v = mean( -1.0, 5.0, 6.0 ); diff --git a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/src/main.c b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/src/main.c index 2dc9c8646518..5290e4988e4a 100644 --- a/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/src/main.c +++ b/lib/node_modules/@stdlib/stats/base/dists/triangular/mean/src/main.c @@ -20,12 +20,12 @@ #include "stdlib/math/base/assert/is_nan.h" /** -* Evaluates the expected value (mean) of a triangular distribution with lower bound a, upper bound b and mode (peak) c. +* Returns the expected value of a triangular distribution. * -* @param a lower bound -* @param b upper bound -* @param c mode (peak) -* @returns expected value (mean) +* @param a minimum support +* @param b maximum support +* @param c mode +* @returns expected value * * @example * double v = mean( 0.0, 10.0, 5.0 );