diff --git a/lib/node_modules/@stdlib/array/docs/types/index.d.ts b/lib/node_modules/@stdlib/array/docs/types/index.d.ts index 608bfbf1519..e7fa9be5cc9 100644 --- a/lib/node_modules/@stdlib/array/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/array/docs/types/index.d.ts @@ -33,6 +33,7 @@ import datespace = require( '@stdlib/array/datespace' ); import arrayDataType = require( '@stdlib/array/dtype' ); import arrayDataTypes = require( '@stdlib/array/dtypes' ); import aempty = require( '@stdlib/array/empty' ); +import aemptyLike = require( '@stdlib/array/empty-like' ); import filledarray = require( '@stdlib/array/filled' ); import filledarrayBy = require( '@stdlib/array/filled-by' ); import Float32Array = require( '@stdlib/array/float32' ); @@ -398,6 +399,54 @@ interface Namespace { */ aempty: typeof aempty; + /** + * Creates an uninitialized array having the same length and data type as a provided input array. + * + * ## Notes + * + * - In browser environments, the function always returns zero-filled arrays. + * - If `dtype` is `'generic'`, the function always returns a zero-filled array. + * - In Node.js versions `>=3.0.0`, the underlying memory of returned typed arrays is **not** initialized. Memory contents are unknown and may contain **sensitive** data. + * + * The function recognizes the following data types: + * + * - `float64`: double-precision floating-point numbers (IEEE 754) + * - `float32`: single-precision floating-point numbers (IEEE 754) + * - `complex128`: double-precision complex floating-point numbers + * - `complex64`: single-precision complex floating-point numbers + * - `int32`: 32-bit two's complement signed integers + * - `uint32`: 32-bit unsigned integers + * - `int16`: 16-bit two's complement signed integers + * - `uint16`: 16-bit unsigned integers + * - `int8`: 8-bit two's complement signed integers + * - `uint8`: 8-bit unsigned integers + * - `uint8c`: 8-bit unsigned integers clamped to `0-255` + * - `generic`: generic JavaScript values + * + * @param x - input array from which to derive the output array length + * @param dtype - data type + * @returns empty array + * + * @example + * var zeros = require( `@stdlib/array/zeros` ); + * + * var x = zeros( 2, 'float32' ); + * // returns [ 0.0, 0.0 ] + * + * var arr = ns.aemptyLike( x ); + * // returns + * + * @example + * var zeros = require( `@stdlib/array/zeros` ); + * + * var x = zeros( 2, 'float64' ); + * // returns [ 0.0, 0.0 ] + * + * var arr = ns.aemptyLike( x ); + * // returns + */ + aemptyLike: typeof aemptyLike; + /** * Returns a filled typed array view of an `ArrayBuffer`. * diff --git a/lib/node_modules/@stdlib/math/base/special/docs/types/index.d.ts b/lib/node_modules/@stdlib/math/base/special/docs/types/index.d.ts index 755ee38ac35..5fee58e75a3 100644 --- a/lib/node_modules/@stdlib/math/base/special/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/math/base/special/docs/types/index.d.ts @@ -2284,18 +2284,19 @@ interface Namespace { coversin: typeof coversin; /** - * Computes the argument of a complex number in radians. + * Computes the argument of a double-precision complex floating-point number in radians. * * ## Notes * * - The argument of a complex number, also known as the phase, is the angle of the radius extending from the origin to the complex number plotted in the complex plane and the positive real axis. * - * @param re - real component - * @param im - imaginary component + * @param z - complex number * @returns argument * * @example - * var phi = ns.cphase( 5.0, 3.0 ); + * var Complex128 = require( `@stdlib/complex/float64` ); + * + * var phi = ns.cphase( new Complex128( 5.0, 3.0 ) ); * // returns ~0.5404 */ cphase: typeof cphase; @@ -2314,15 +2315,24 @@ interface Namespace { cpolar: typeof cpolar; /** - * Rounds a complex number to the nearest integer. + * Rounds each component of a double-precision complex floating-point number to the nearest integer. * - * @param re - real component - * @param im - imaginary component - * @returns real and imaginary components + * @param z - input value + * @returns result * * @example - * var out = ns.cround( 5.5, 3.3 ); - * // returns [ 6.0, 3.0 ] + * var Complex128 = require( `@stdlib/complex/float64` ); + * var real = require( `@stdlib/complex/real` ); + * var imag = require( `@stdlib/complex/imag` ); + * + * var v = cceil( new Complex128( -4.2, 5.5 ) ); + * // returns + * + * var re = real( v ); + * // returns -4.0 + * + * var im = imag( v ); + * // returns 6.0 */ cround: typeof cround; @@ -2369,23 +2379,24 @@ interface Namespace { csch: typeof csch; /** - * Evaluates the signum function of a complex number. + * Evaluates the signum function of a double-precision complex floating-point number. * - * @param re - real component - * @param im - imaginary component - * @returns real and imaginary components + * @param z - input value + * @returns result * * @example - * var v = ns.csignum( -4.2, 5.5 ); - * // returns [ -0.6069136033622302, 0.79476781392673 ] + * var Complex128 = require( `@stdlib/complex/float64` ); + * var real = require( `@stdlib/complex/real` ); + * var imag = require( `@stdlib/complex/imag` ); * - * @example - * var v = ns.csignum( 0.0, 0.0 ); - * // returns [ 0.0, 0.0 ] + * var v = cceil( new Complex128( -4.2, 5.5 ) ); + * // returns * - * @example - * var v = ns.csignum( NaN, NaN ); - * // returns [ NaN, NaN ] + * var re = real( v ); + * // returns -0.6069136033622302 + * + * var im = imag( v ); + * // returns 0.79476781392673 */ csignum: typeof csignum; diff --git a/lib/node_modules/@stdlib/string/base/distances/docs/types/index.d.ts b/lib/node_modules/@stdlib/string/base/distances/docs/types/index.d.ts index 9ed033a47a6..60e3769c625 100644 --- a/lib/node_modules/@stdlib/string/base/distances/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/string/base/distances/docs/types/index.d.ts @@ -42,7 +42,6 @@ interface Namespace { * var dist = ns.levenshteinDistance( 'algorithm', 'altruistic' ); * // returns 6 * - * * @example * var dist = ns.levenshteinDistance( 'hippo', 'elephant' ); * // returns 7 diff --git a/lib/node_modules/@stdlib/string/docs/types/index.d.ts b/lib/node_modules/@stdlib/string/docs/types/index.d.ts index ea571e2d4a8..841f98ba2c8 100644 --- a/lib/node_modules/@stdlib/string/docs/types/index.d.ts +++ b/lib/node_modules/@stdlib/string/docs/types/index.d.ts @@ -27,8 +27,10 @@ import camelcase = require( '@stdlib/string/camelcase' ); import capitalize = require( '@stdlib/string/capitalize' ); import codePointAt = require( '@stdlib/string/code-point-at' ); import constantcase = require( '@stdlib/string/constantcase' ); +import dotcase = require( '@stdlib/string/dotcase' ); import endsWith = require( '@stdlib/string/ends-with' ); import first = require( '@stdlib/string/first' ); +import forEach = require( '@stdlib/string/for-each' ); import format = require( '@stdlib/string/format' ); import fromCodePoint = require( '@stdlib/string/from-code-point' ); import kebabcase = require( '@stdlib/string/kebabcase' ); @@ -186,6 +188,26 @@ interface Namespace { */ constantcase: typeof constantcase; + /** + * Converts a string to dot case. + * + * @param str - string to convert + * @returns dot-cased string + * + * @example + * var str = ns.dotcase( 'Hello World!' ); + * // returns 'hello.world' + * + * @example + * var str = ns.dotcase( 'foo_bar' ); + * // returns 'foo.bar' + * + * @example + * var str = ns.dotcase( 'foo-bar' ); + * // returns 'foo.bar' + */ + dotcase: typeof dotcase; + /** * Tests if a string ends with the characters of another string. * @@ -253,6 +275,33 @@ interface Namespace { */ first: typeof first; + /** + * Invokes a callback once for each (visual) character of a string. + * + * ## Notes + * + * - When invoked, the input function is provided three arguments: + * + * - `value`: visual character + * - `index`: starting character index + * - `inpStr`: input string + * + * @param str - input string + * @param clbk - function to invoke + * @param thisArg - execution context + * @returns input string + * + * @example + * function log( value, index, inpStr ) { + * console.log( '%s: %d', index, value ); + * } + * + * var testStr = 'presidential election'; + * + * ns.forEach( testStr, log ); + */ + forEach: typeof forEach; + /** * Inserts supplied variable values into a format string. *