docs: move JS examples before C API documentation#12704
Merged
Conversation
Reorders the README to place the JavaScript `## Examples` section between the JS `## Usage` and `## C APIs` sections, matching the layout used by the other 11 native-addon packages in `stats/base/dists/gamma` (92% conformance: entropy, kurtosis, logcdf, logpdf, mean, mgf, mode, pdf, skewness, stdev, variance). Section content is unchanged; only the block position and an interior `* * *` separator move.
Contributor
Coverage Report
The above coverage report was generated for the changes in this PR. |
kgryte
approved these changes
Jun 8, 2026
stats/base/dists/gamma/cdf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Reorders the README in
stats/base/dists/gamma/cdfso the JavaScript## Examplessection sits between the JS## Usageand## C APIssections — the layout shared by every other native-addon package in the namespace.Namespace summary
@stdlib/stats/base/dists/gammacdf,ctor,entropy,kurtosis,logcdf,logpdf,mean,mgf,mode,pdf,quantile,skewness,stdev,variance)package.jsonshape,manifest.jsonshape, README heading sequence,test//benchmark//examples/naming, public signature, validation prologue, error construction, JSDoc shape,require-graph dependencies.isnanusage (5 of 7 omit it, 71% — under threshold).stats/base/dists/gamma/cdfThe README ordered sections as
## Usage→## C APIs→## Examples, with the JS example block buried after the C interface. Every other native-addon sibling in the namespace (entropy,kurtosis,logcdf,logpdf,mean,mgf,mode,pdf,skewness,stdev,variance— 11 of 12, 92%) places the JS## Examplesbefore the## C APIsseparator. The block, its enclosing<section class="examples">wrapper, and the surrounding* * *separator move as a unit; section content is byte-identical.Related Issues
None.
Questions
No.
Other
Validation
Structural features were extracted by walking each package's tree and parsing
package.json,manifest.json, and README headings. Semantic features (public signatures, validation prologue, error construction, JSDoc shape,require-graph dependencies) were read directly from each package'slib/main.js,lib/factory.js, andlib/index.js. The single advancing candidate was vetted by a structural-review agent (confirmed the entropy-style ordering as the correct target and the block move as content-preserving) and a cross-reference agent (confirmed no anchor links, no test/benchmark code, no umbrella-namespace tooling, and no markdown-lint rule depends on the current ordering).Deliberately excluded:
ctor,quantilelackinggypfile/binding.gyp/src//include//manifest.json— intentional:ctoris a constructor with no native math kernel,quantileis awaiting the in-flightmath/base/special/gammaincinvC implementation (PR feat: add C implementation formath/base/special/gammaincinv#9982). Per gate "Ecosystem-wide intentional absence."pdf/LICENSE(only gamma member with a per-package LICENSE file) — direction of fix would be removal, but per-package LICENSEs appear in <2% of stdlib; without git-blame intent the safe call is to log and defer to a maintainer.mgfpackage.json missingprobabilitykeyword (13/14 of gamma siblings have it) — but only 2 of 22 MGF packages acrossstats/base/dists(9% stdlib-wide) carry it, so the namespace-local majority reflects the local minority, not drift. Gate "Ecosystem-wide intentional absence" applies.isnanusage — 5 of 7 scalar functions (entropy,mean,mode,stdev,variance) omit explicitisnanchecks; 2 (kurtosis,skewness) include them. 71% conformance is below the 75% threshold, no clear majority.PR #12677 (open draft) touches
gamma/mgf/lib/factory.jsonly for wording propagation — no overlap with this diff.Checklist
AI Assistance
If you answered "yes" above, how did you use AI assistance?
Disclosure
This PR was authored by Claude Code as part of the cross-package drift-detection routine. Structural and semantic features were extracted programmatically across the namespace; the single advancing candidate was independently vetted by a structural-review agent and a cross-reference agent before the section reorder was applied. A human maintainer should verify the diff before promoting this PR out of draft.
@stdlib-js/reviewers
Generated by Claude Code