From 4415b33978b60344686fd8200bf6b87077bcd371 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 9 Jun 2026 04:24:52 +0000 Subject: [PATCH 1/2] docs: align `stats/strided/distances/dcorrelation` JSDoc, README, and keywords with siblings Bring `dcorrelation` into conformance with the seven sibling packages in `stats/strided/distances`: - `lib/{dcorrelation,ndarray}.js` and the `.native.js` counterparts: retype `@param {PositiveInteger} N` to `@param {NonNegativeInteger} N`. The function explicitly returns `NaN` for `N <= 0` (asserted in `test/test.dcorrelation.js`, `test/test.ndarray.js`, and the native test variants); 7/8 siblings annotate `N` as `NonNegativeInteger`. JSDoc-only change; no runtime impact. - `README.md`: replace the abbreviated `sx, ox, sy, oy` placeholders in the `stdlib_strided_dcorrelation_ndarray` H4 heading with `strideX, offsetX, strideY, offsetY`, matching the literal C signature already present on line 248 of the same README and the published header. 7/8 siblings use the full parameter names in the heading. - `package.json`: insert `metric` between `distance` and `strided` in the keywords array, matching the position used by all seven sibling packages (87.5% conformance). No source, test, or behavioral changes. https://claude.ai/code/session_017aK2GkAL5Rpde789kYBtnN --- .../@stdlib/stats/strided/distances/dcorrelation/README.md | 2 +- .../stats/strided/distances/dcorrelation/lib/dcorrelation.js | 2 +- .../strided/distances/dcorrelation/lib/dcorrelation.native.js | 2 +- .../@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.js | 2 +- .../stats/strided/distances/dcorrelation/lib/ndarray.native.js | 2 +- .../@stdlib/stats/strided/distances/dcorrelation/package.json | 1 + 6 files changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md index a538adaa4542..b438a5b05a0a 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md @@ -222,7 +222,7 @@ The function accepts the following arguments: double stdlib_strided_dcorrelation( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY ); ``` -#### stdlib_strided_dcorrelation_ndarray( N, \*X, sx, ox, \*Y, sy, oy ) +#### stdlib_strided_dcorrelation_ndarray( N, \*X, strideX, offsetX, \*Y, strideY, offsetY ) Computes the [correlation distance][correlation-distance] between two double-precision floating-point strided arrays using alternative indexing semantics. diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.js b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.js index 5e019d43e58d..631f3073da8b 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.js +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.js @@ -29,7 +29,7 @@ var ndarray = require( './ndarray.js' ); /** * Computes the correlation distance between two double-precision floating-point strided arrays. * -* @param {PositiveInteger} N - number of indexed elements +* @param {NonNegativeInteger} N - number of indexed elements * @param {Float64Array} x - first input array * @param {integer} strideX - stride length of `x` * @param {Float64Array} y - second input array diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.native.js b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.native.js index f60586e84bce..0845ea02fc77 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.native.js +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/dcorrelation.native.js @@ -28,7 +28,7 @@ var addon = require( './../src/addon.node' ); /** * Computes the correlation distance between two double-precision floating-point strided arrays. * -* @param {PositiveInteger} N - number of indexed elements +* @param {NonNegativeInteger} N - number of indexed elements * @param {Float64Array} x - first input array * @param {integer} strideX - stride length of `x` * @param {Float64Array} y - second input array diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.js b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.js index 643a912c557c..fcc31427fc8f 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.js +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.js @@ -28,7 +28,7 @@ var dpcorr = require( '@stdlib/stats/strided/dpcorr' ).ndarray; /** * Computes the correlation distance between two double-precision floating-point strided arrays using alternative indexing semantics. * -* @param {PositiveInteger} N - number of indexed elements +* @param {NonNegativeInteger} N - number of indexed elements * @param {Float64Array} x - first input array * @param {integer} strideX - stride length of `x` * @param {NonNegativeInteger} offsetX - starting index of `x` diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.native.js b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.native.js index 5c4013b5f5bf..922da392d5c3 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.native.js +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/lib/ndarray.native.js @@ -28,7 +28,7 @@ var addon = require( './../src/addon.node' ); /** * Computes the correlation distance between two double-precision floating-point strided arrays using alternative indexing semantics. * -* @param {PositiveInteger} N - number of indexed elements +* @param {NonNegativeInteger} N - number of indexed elements * @param {Float64Array} x - first input array * @param {integer} strideX - stride length of `x` * @param {NonNegativeInteger} offsetX - starting index of `x` diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/package.json b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/package.json index 2621cb88f48f..32aa41c605bc 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/package.json +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/package.json @@ -62,6 +62,7 @@ "dcorrelation", "correlation", "distance", + "metric", "strided", "strided array", "typed", From a000843e6fb3ed25d8de39f58bfab4efe635c335 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 9 Jun 2026 04:29:19 +0000 Subject: [PATCH 2/2] docs: revert README C API heading change in `stats/strided/distances/dcorrelation` The earlier substitution of the abbreviated `sx, ox, sy, oy` placeholders with the full `strideX, offsetX, strideY, offsetY` matched the sibling pattern but tripped the project-wide `remark-lint` `maximum-heading-length` rule (80 characters). All seven sibling READMEs in `stats/strided/distances` exceed this limit too (89-97 characters), but the rule only runs against READMEs touched by a PR, so the failure surfaces only here. Restoring the abbreviated form (70 characters) keeps CI green. The README's argument list (lines 241-245) and the literal C signature in the same file's code block (line 248) already use the full `strideX, offsetX, strideY, offsetY` names, so the readers' reference is unambiguous; the heading is the lone deviation. A proper fix for the namespace-wide heading-length drift belongs to a separate pass. https://claude.ai/code/session_017aK2GkAL5Rpde789kYBtnN --- .../@stdlib/stats/strided/distances/dcorrelation/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md index b438a5b05a0a..a538adaa4542 100644 --- a/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md +++ b/lib/node_modules/@stdlib/stats/strided/distances/dcorrelation/README.md @@ -222,7 +222,7 @@ The function accepts the following arguments: double stdlib_strided_dcorrelation( const CBLAS_INT N, const double *X, const CBLAS_INT strideX, const double *Y, const CBLAS_INT strideY ); ``` -#### stdlib_strided_dcorrelation_ndarray( N, \*X, strideX, offsetX, \*Y, strideY, offsetY ) +#### stdlib_strided_dcorrelation_ndarray( N, \*X, sx, ox, \*Y, sy, oy ) Computes the [correlation distance][correlation-distance] between two double-precision floating-point strided arrays using alternative indexing semantics.