-
-
Notifications
You must be signed in to change notification settings - Fork 903
feat: add stats/incr/nanvariance
function
#5755
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
feat: add stats/incr/nanvariance
function
#5755
Conversation
Signed-off-by: Gautam sharma <[email protected]>
Signed-off-by: Gautam sharma <[email protected]>
Coverage Report
The above coverage report was generated for the changes in this PR. |
Signed-off-by: Gautam sharma <[email protected]>
Signed-off-by: Gautam sharma <[email protected]>
Signed-off-by: Gautam sharma <[email protected]>
stats/incr/nanvariance
#5626 stats/incr/nanvariance
function
@kgryte please review once it has some linting issues that i will fix soon but please review the main implementation of it and suggest the changes i can do in it |
hello @anandkaranubc please review |
@@ -0,0 +1,57 @@ | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This entire file is incorrect. Please follow our repl text style guide and avoid using LLMs to generate files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it was showing warning in the linting years so i added that licence code in that but now i have resolved it please check is that exactly you wanted
|
||
// The compiler throws an error if the function is provided invalid arguments... | ||
{ | ||
incrnanvariance( '5' as any ); // $ExpectError |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove all of these as any
casts. The entire point of these lines is to test that the compiler errors when provided various non-any input values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i did it because it was showing some ecmacript error in it but i have changed it now and removed the as any from there please review
lib/node_modules/@stdlib/stats/incr/nanvariance/docs/types/test.ts
Outdated
Show resolved
Hide resolved
* v = accumulator(); | ||
* // returns 33.7796 | ||
*/ | ||
function incrnanvariance( mean ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This implementation is not what is desired. As mentioned in the OP,
In particular notice how nansum is a thin wrapper around sum. In most cases, this is what we are looking for.
You're essentially duplicating the incr/variance
implementation. That is not what we want. Create a thin wrapper similar to nansum
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i got confused between both i have changed please check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left an initial round of comments. This PR needs a fair amount of refactoring and clean-up before it can be merged.
okay @kgryte working on it |
@kgryte i did the changes in this you wanted me to change and i have fixed the linting issues also please review and i am creating the readme for nanvariance also |
@kgryte please review !! |
@kgryte please review ! |
@Krishna-Sharma-g This package is missing a README file. |
Resolves #{{TODO: add issue number}}.
#5626
This pull request:
Related Issues
This pull request:
stats/incr/nanvariance
#5626Questions
No.
Other
all three test commands passes
No.
Checklist
@stdlib-js/reviewers