Skip to content

feat: add C implementation for stats/base/ndarray/dnanmeanpn - #14120

Merged
kgryte merged 4 commits into
stdlib-js:developfrom
ujjwalv01:feat-stats-base-ndarray-dnanmeanpn-c
Aug 11, 2026
Merged

feat: add C implementation for stats/base/ndarray/dnanmeanpn#14120
kgryte merged 4 commits into
stdlib-js:developfrom
ujjwalv01:feat-stats-base-ndarray-dnanmeanpn-c

Conversation

@ujjwalv01

Copy link
Copy Markdown
Contributor

Resolves a part of #14034

Description

What is the purpose of this pull request?

This pull request:

  • Adds a native C implementation for @stdlib/stats/base/ndarray/dnanmeanpn
  • Includes corresponding C and JavaScript benchmark suites
  • Exposes native bindings via Node-API
  • Adds tests to ensure parity between JavaScript and C implementations

Related Issues

Does this pull request have any related issues?

This pull request has the following related issues:

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

No.

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

If you answered "yes" to using AI assistance, please provide a short disclosure indicating how you used AI assistance. This helps reviewers determine how much scrutiny to apply when reviewing your contribution. Example disclosures: "This PR was written primarily by Claude Code." or "I consulted ChatGPT to understand the codebase, but the proposed changes were fully authored manually by myself.".

I utilized AI assistance strictly to help check, split, and reformat the existing JavaScript test and benchmark suites for the native implementation fallback logic. The C implementation and native architecture were manually verified.


@stdlib-js/reviewers

@stdlib-bot stdlib-bot added the Statistics Issue or pull request related to statistical functionality. label Aug 10, 2026
@stdlib-bot

stdlib-bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Coverage Report

No coverage information available.

@ujjwalv01
ujjwalv01 marked this pull request as ready for review August 10, 2026 13:12
@ujjwalv01
ujjwalv01 requested a review from a team August 10, 2026 13:12
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label Aug 10, 2026
@kgryte kgryte added Feature Issue or pull request for adding a new feature. C Issue involves or relates to C. difficulty: 2 May require some initial design or R&D, but should be straightforward to resolve and/or implement. and removed Needs Review A pull request which needs code review. labels Aug 11, 2026
Comment thread lib/node_modules/@stdlib/stats/base/ndarray/dnanmeanpn/benchmark/benchmark.js Outdated
Comment thread lib/node_modules/@stdlib/stats/base/ndarray/dnanmeanpn/src/main.c Outdated
Comment thread lib/node_modules/@stdlib/stats/base/ndarray/dnanmeanpn/README.md Outdated
Comment thread lib/node_modules/@stdlib/stats/base/ndarray/dnanmeanpn/README.md Outdated
Co-authored-by: Athan <kgryte@gmail.com>
Signed-off-by: Athan <kgryte@gmail.com>

@kgryte kgryte left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM after clean-up.

@kgryte
kgryte merged commit 473d131 into stdlib-js:develop Aug 11, 2026
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C Issue involves or relates to C. difficulty: 2 May require some initial design or R&D, but should be straightforward to resolve and/or implement. Feature Issue or pull request for adding a new feature. review: 3 Statistics Issue or pull request related to statistical functionality.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants