Mathjs: quantileSeq has inconsistant return

Created on 4 Sep 2018  路  2Comments  路  Source: josdejong/mathjs

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.

bug

All 2 comments

Very nice that this issue pops up now with assert.strictEqual :+1:

Was this page helpful?
0 / 5 - 0 ratings