Skip to content

Commit

Permalink
Auto-generated commit
Browse files Browse the repository at this point in the history
  • Loading branch information
stdlib-bot committed Jan 7, 2024
1 parent ed60600 commit 6ce541a
Show file tree
Hide file tree
Showing 24 changed files with 62 additions and 64 deletions.
2 changes: 1 addition & 1 deletion array/bernoulli/benchmark/benchmark.float32.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var bench = require( '@stdlib/bench' );
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
var pow = require( '@stdlib/math/base/special/pow' );
var pkg = require( './../package.json' ).name;
var random = require('./../lib');
var random = require( './../lib' );


// FUNCTIONS //
Expand Down
2 changes: 1 addition & 1 deletion array/bernoulli/benchmark/benchmark.float32.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var bench = require( '@stdlib/bench' );
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
var pow = require( '@stdlib/math/base/special/pow' );
var pkg = require( './../package.json' ).name;
var random = require('./../lib');
var random = require( './../lib' );


// FUNCTIONS //
Expand Down
14 changes: 7 additions & 7 deletions array/bernoulli/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
Output array length.

p: number
Success probability (i.e., a value on the interval [0,1]).
Success probability.

options: Object (optional)
Options.
Expand All @@ -35,7 +35,7 @@
Parameters
----------
p: number
Success probability (i.e., a value on the interval [0,1]).
Success probability.

out: Array<number>|TypedArray
Output array.
Expand All @@ -58,11 +58,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from a Bernoulli distribution.

If provided `p`, the returned function returns random variates drawn from
the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `p`, the returned function requires that `p` be provided at
each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand All @@ -72,7 +72,7 @@
Parameters
----------
p: number (optional)
Success probability (i.e., a value on the interval [0,1]).
Success probability.

options: Object (optional)
Options.
Expand Down
8 changes: 4 additions & 4 deletions array/bernoulli/docs/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ interface Random extends PRNG {
* @returns output array
*
* @example
* var out = bernoulli 10, 0.5 );
* var out = bernoulli( 10, 0.5 );
* // returns <Float64Array>
*/
( len: number, p: number, options?: Options ): RandomArray;
Expand All @@ -185,7 +185,7 @@ interface Random extends PRNG {
* var x = zeros( 10, 'float64' );
* // returns <Float64Array>
*
* var out = bernoulli 0.5, out );
* var out = bernoulli( 0.5, out );
* // returns <Float64Array>
*
* var bool = ( out === x );
Expand All @@ -202,7 +202,7 @@ interface Random extends PRNG {
*
* @param p - success probability
* @param options - function options
* @throws `p` must be a probability
* @throws `p` must be a probability (i.e., a number on the interval [0,1])
* @throws must provide a valid state
* @returns function for creating arrays
*
Expand Down Expand Up @@ -257,7 +257,7 @@ interface Random extends PRNG {
* @returns output array
*
* @example
* var out = bernoulli 10, 0.5 );
* var out = bernoulli( 10, 0.5 );
* // returns <Float64Array>
*
* @example
Expand Down
8 changes: 4 additions & 4 deletions array/bernoulli/lib/factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,28 +38,28 @@ var DTYPES = dtypes( 'real_and_generic' );
*
* @name factory
* @type {Function}
* @param {Probability} [p] - success probability
* @param {PositiveNumber} [p] - success probability
* @param {Options} [options] - function options
* @param {PRNG} [options.prng] - pseudorandom number generator which generates uniformly distributed pseudorandom numbers
* @param {PRNGSeedMT19937} [options.seed] - pseudorandom number generator seed
* @param {PRNGStateMT19937} [options.state] - pseudorandom number generator state
* @param {boolean} [options.copy=true] - boolean indicating whether to copy a provided pseudorandom number generator state
* @param {string} [options.dtype="float64"] - default data type
* @throws {TypeError} `p` must be a probability
* @throws {TypeError} `p` must be a probability (i.e., a number on the interval [0,1])
* @throws {TypeError} options argument must be an object
* @throws {TypeError} must provide valid options
* @throws {Error} must provide a valid state
* @returns {Function} function for creating arrays
*
* @example
* var bernoulli = factory( 0.3 );
* var bernoulli = factory( 0.5 );
* // returns <Function>
*
* var arr = bernoulli( 10 );
* // returns <Float64Array>
*
* @example
* var bernoulli = factory( 0.3 );
* var bernoulli = factory( 0.5 );
* // returns <Function>
*
* var arr = bernoulli( 10, {
Expand Down
8 changes: 4 additions & 4 deletions array/chi/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from a chi distribution.

If provided `k`, the returned function returns random variates drawn from
the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `k`, the returned function requires that `k` be provided at
each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand Down
3 changes: 1 addition & 2 deletions array/chi/docs/types/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ import random = require( './index' );
// The function returns an array...
{
random( 10, 2.0 ); // $ExpectType RandomArray
random( 10, 1.0 ); // $ExpectType RandomArray
random( 10, 1.0, {} ); // $ExpectType RandomArray
random( 10, 2.0, {} ); // $ExpectType RandomArray
}

// The compiler throws an error if the function is provided a first argument which is not a number...
Expand Down
4 changes: 2 additions & 2 deletions array/chi/test/test.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}

random = factory();
Expand All @@ -746,7 +746,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
2 changes: 1 addition & 1 deletion array/chi/test/test.main.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ tape( 'the function returns an array containing pseudorandom numbers (default)',
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
8 changes: 4 additions & 4 deletions array/exponential/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from an exponential distribution.

If provided `lambda`, the returned function returns random variates drawn
from the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `lambda`, the returned function requires that `lambda` be
provided at each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand Down
4 changes: 2 additions & 2 deletions array/exponential/test/test.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}

random = factory();
Expand All @@ -746,7 +746,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
2 changes: 1 addition & 1 deletion array/exponential/test/test.main.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ tape( 'the function returns an array containing pseudorandom numbers (default)',
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
2 changes: 1 addition & 1 deletion array/geometric/benchmark/benchmark.float32.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var bench = require( '@stdlib/bench' );
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
var pow = require( '@stdlib/math/base/special/pow' );
var pkg = require( './../package.json' ).name;
var random = require('./../lib');
var random = require( './../lib' );


// FUNCTIONS //
Expand Down
2 changes: 1 addition & 1 deletion array/geometric/benchmark/benchmark.float32.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ var bench = require( '@stdlib/bench' );
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
var pow = require( '@stdlib/math/base/special/pow' );
var pkg = require( './../package.json' ).name;
var random = require('./../lib');
var random = require( './../lib' );


// FUNCTIONS //
Expand Down
14 changes: 7 additions & 7 deletions array/geometric/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
Output array length.

p: number
Success probability (i.e., a value on the interval [0,1]).
Success probability.

options: Object (optional)
Options.
Expand All @@ -35,7 +35,7 @@
Parameters
----------
p: number
Success probability (i.e., a value on the interval [0,1]).
Success probability.

out: Array<number>|TypedArray
Output array.
Expand All @@ -58,11 +58,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from a geometric distribution.

If provided `p`, the returned function returns random variates drawn from
the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `p`, the returned function requires that `p` be provided at
each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand All @@ -72,7 +72,7 @@
Parameters
----------
p: number (optional)
Success probability (i.e., a value on the interval [0,1]).
Success probability.

options: Object (optional)
Options.
Expand Down
2 changes: 1 addition & 1 deletion array/geometric/docs/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ interface Random extends PRNG {
*
* @param p - success probability
* @param options - function options
* @throws `p` must be a probability
* @throws `p` must be a probability (i.e., a number on the interval [0,1])
* @throws must provide a valid state
* @returns function for creating arrays
*
Expand Down
8 changes: 4 additions & 4 deletions array/geometric/lib/factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,28 +38,28 @@ var DTYPES = dtypes( 'real_and_generic' );
*
* @name factory
* @type {Function}
* @param {Probability} [p] - success probability
* @param {PositiveNumber} [p] - success probability
* @param {Options} [options] - function options
* @param {PRNG} [options.prng] - pseudorandom number generator which generates uniformly distributed pseudorandom numbers
* @param {PRNGSeedMT19937} [options.seed] - pseudorandom number generator seed
* @param {PRNGStateMT19937} [options.state] - pseudorandom number generator state
* @param {boolean} [options.copy=true] - boolean indicating whether to copy a provided pseudorandom number generator state
* @param {string} [options.dtype="float64"] - default data type
* @throws {TypeError} `p` must be a probability
* @throws {TypeError} `p` must be a probability (i.e., a number on the interval [0,1])
* @throws {TypeError} options argument must be an object
* @throws {TypeError} must provide valid options
* @throws {Error} must provide a valid state
* @returns {Function} function for creating arrays
*
* @example
* var geometric = factory( 0.3 );
* var geometric = factory( 0.01 );
* // returns <Function>
*
* var arr = geometric( 10 );
* // returns <Float64Array>
*
* @example
* var geometric = factory( 0.3 );
* var geometric = factory( 0.01 );
* // returns <Function>
*
* var arr = geometric( 10, {
Expand Down
8 changes: 4 additions & 4 deletions array/poisson/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from a Poisson distribution.

If provided `lambda`, the returned function returns random variates drawn
from the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `lambda`, the returned function requires that `lambda` be
provided at each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand Down
4 changes: 2 additions & 2 deletions array/poisson/test/test.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}

random = factory();
Expand All @@ -746,7 +746,7 @@ tape( 'the function returns a function for creating arrays containing pseudorand
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
2 changes: 1 addition & 1 deletion array/poisson/test/test.main.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ tape( 'the function returns an array containing pseudorandom numbers (default)',
t.strictEqual( actual.length, 10, 'returns expected value' );

for ( i = 0; i < actual.length; i++ ) {
t.strictEqual( typeof actual[ i ], 'number', 'returns expected value for index '+i );
t.strictEqual( actual[ i ], actual[ i ], 'returns expected value for index '+i );
}
t.end();
});
Expand Down
11 changes: 5 additions & 6 deletions array/rayleigh/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@


{{alias}}.assign( sigma, out )
Fills an array with pseudorandom numbers drawn from a Rayleigh
distribution.
Fills an array with pseudorandom numbers drawn from a Rayleigh distribution.

Parameters
----------
Expand Down Expand Up @@ -58,11 +57,11 @@
Returns a function for creating arrays containing pseudorandom numbers drawn
from a Rayleigh distribution.

If provided `sigma`, the returned function returns random variates drawn
from the specified distribution.
If provided a distribution parameter, the returned function returns random
variates drawn from the specified distribution.

If not provided `sigma`, the returned function requires that `sigma` be
provided at each invocation.
If not provided a distribution parameter, the returned function requires
that distribution parameters be provided at each invocation.

The returned function accepts the following options:

Expand Down
Loading

0 comments on commit 6ce541a

Please sign in to comment.