Repository navigation
docs: add entropy property docs to stats/base/dists/invgamma/ctor - #15598
Merged
kgryte merged 1 commit intoSep 27, 2026
Merged
Conversation
Document the `InvGamma.prototype.entropy` computed property, which the constructor exposes but the README omitted. Drift items corrected: - Added a missing `#### InvGamma.prototype.entropy` entry to the README "Computed Properties" section. Of the 28 `stats/base/dists/*/ctor` packages defining an `entropy` accessor, 27 document it (96%); `invgamma` was the sole omission. The accessor is already documented in `docs/repl.txt` and `docs/types/index.d.ts`. - Added the corresponding `[entropy]` link reference definition, placed between `[quantile-function]` and `[expected-value]` to match the ordering used by sibling `ctor` READMEs. The documented value matches `invgamma/entropy`'s own README example for the same arguments. Documentation only; no change to source, tests, or observable behavior. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015e4mqygYr6qHfirXEFiYja
Contributor
Coverage Report
The above coverage report was generated for the changes in this PR. |
kgryte
marked this pull request as ready for review
September 27, 2026 21:56
kgryte
approved these changes
Sep 27, 2026
kgryte
deleted the
philipp/drift-stats-base-dists-invgamma-2026-09-27
branch
September 27, 2026 21:57
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
This pull request documents a computed property which
stats/base/dists/invgamma/ctorexposes but whose README omitted it.#### InvGamma.prototype.entropyentry to the README's "Computed Properties" section, plus the matching[entropy]link reference definition.Namespace summary
This change came out of a cross-package consistency audit of the
stats/base/dists/invgammanamespace.cdf,ctor,entropy,kurtosis,logpdf,mean,mode,pdf,quantile,skewness,stdev,variance); none autogenerated.package.jsonkey set,manifest.jsonkey set, README heading sequence,test/benchmark/examplesfilenames) and semantic (public signature, return kind, validation prologue, error construction, JSDoc shape, source-level dependencies).@returnstype (PositiveNumber6/12), full validation-prologue sequence (largest 3/12),lib/factory.jsand its companion tests (4/12), Julia fixture layout (7/12), and thescripts/stdlibpackage.jsonkeys (absent in all 12).Across all 15 features with a clear majority,
ctorwas the only outlier, and in every case the deviation is correct rather than drift:ctoris a pure-JavaScript distribution-object constructor with no native backend. All 34stats/base/dists/*/ctorpackages lackbinding.gypandmanifest.json, so the native-addon file set, thegypfilefield, the object-API README heading sequence, and the throwing constructor contract are all intentional. None of those became corrections.stats/base/dists/invgamma/ctorAdds the missing
InvGamma.prototype.entropyentry to the README's "Computed Properties" section and its[entropy]link reference definition, matching the pattern used by siblingctorREADMEs. The accessor itself already exists inlib/main.jsand is documented indocs/repl.txtanddocs/types/index.d.ts; only the README lacked it. Of the 28stats/base/dists/*/ctorpackages defining anentropyaccessor, 27 document it in their README (96% conformance) —invgamma/ctorwas the outlier. Documentation only; no source, test, or behavior changes.Related Issues
No.
Questions
The entry is placed first in "Computed Properties" to preserve that section's alphabetical ordering, which is how
gamma/ctor,beta/ctor, andlognormal/ctororder theirs. Say so if you would rather it go elsewhere in the section.Other
Validation
Checked:
package.json/manifest.jsonkey sets, README heading sequences, test/benchmark/example filenames), with package-specific filenames normalized so per-package names did not each read as unique.require()-level dependencies).~1.996fornew InvGamma( 4.0, 12.0 )matches the example already ininvgamma/entropy/README.mdfor the same arguments, and was recomputed directly againstinvgamma/entropy.## See Alsosection nor any other auto-populated region.Deliberately excluded:
ctordeviation from the 12-member majority traces to its being a pure-JS constructor rather than a scalar function; confirmed against all 34stats/base/dists/*/ctorpackages.ctor's throwing validation or dropping its optional-argument defaults would breaktest/test.js,docs/types/test.ts, and four documentation surfaces including the parent namespace README.gamma, and reordering would be behaviorally inert, so nothing was changed.gypfilepresence acrossstats/base/distsis 474/569 (83%), below the 90% bar required before treating absence as drift.Checklist
AI Assistance
If you answered "yes" above, how did you use AI assistance?
Disclosure
This PR was written primarily by Claude Code. It ran an automated cross-package consistency audit of the
stats/base/dists/invgammanamespace, and the single documentation addition here is the only finding that survived filtering. The added README entry was copied from the template used by siblingctorpackages, and the documented value was recomputed againstinvgamma/entropyand cross-checked against that package's own README example.@stdlib-js/reviewers
Generated by Claude Code