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

quantileSeq has inconsistant return #1236

Closed
harrysarson opened this Issue Sep 4, 2018 · 2 comments

Comments

Projects
None yet
2 participants
@harrysarson
Collaborator

harrysarson commented Sep 4, 2018

I found that quantileSeq has an inconsistent return:

  • math.quantileSeq([1,2,3,4,5], math.bignumber(.2)) returns bignumber(1.8).
  • math.quantileSeq([1,2,3,4,5], math.bignumber(.25)) returns 2 (a non big number).

This should have been flagged by mathjs tests but node's assert.equal has let us down. I found this whilst swapping assert.equal for assert.strictEqual.

I am fairly confident that this is a bug.

@harrysarson harrysarson added the bug label Sep 4, 2018

harrysarson added a commit that referenced this issue Sep 4, 2018

Fix most errors due to assert.strictEquals
Some instances of `strictEquals` are replaced by `deepEquals`.
`toString` has been used to make some string comparisions explicit.
Tests will still fail untill #1236 and #1237 are fixed.

josdejong added a commit that referenced this issue Sep 8, 2018

@josdejong

This comment has been minimized.

Show comment
Hide comment
@josdejong

josdejong Sep 8, 2018

Owner

Very nice that this issue pops up now with assert.strictEqual 👍

Owner

josdejong commented Sep 8, 2018

Very nice that this issue pops up now with assert.strictEqual 👍

@josdejong

This comment has been minimized.

Show comment
Hide comment
@josdejong

josdejong Sep 8, 2018

Owner

Should be fixed now via 4e1bed2

Owner

josdejong commented Sep 8, 2018

Should be fixed now via 4e1bed2

@josdejong josdejong closed this in c5971b3 Sep 8, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment