question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

support "and a half" in values()

See original GitHub issue

nlp_compromise.value("5 and a half").number is equal to 6. It should be equal to 5.5. I am using the latest from head.

Issue Analytics

  • State:open
  • Created 7 years ago
  • Comments:19 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
LakshSinglacommented, Oct 17, 2018

Alright, thanks for your help. I will push the commit with reference to a half test cases today and mention it here in the comment. The current code for a half and related does not work and I suspect it may have something to do with values() you mentioned above. Also regarding #1 it is working on values such as seven and a half or seven eleven and a half but failing on tests like seven and a half eleven. I will look into that today too.

0reactions
spencermountaincommented, May 3, 2021

thank you @ampyard-akshay-sushir - i think a lot of these examples have been solved by https://github.com/spencermountain/compromise/pull/799 note that the api has changed a lot in the 5 years since this ticket was created. maybe it would be helpful to find any issues you can with natural-language fractions, and create a new ticket, then we can discuss how to fix them, sound good? cheers!

Read more comments on GitHub >

github_iconTop Results From Across the Web

4.5.1 Calculating the range and interquartile range
The semi-interquartile range is half the interquartile range. When the data set is small, it is simple to identify the values of quartiles....
Read more >
AVERAGEIF function - Microsoft Support
Returns the average (arithmetic mean) of all the cells in a range that meet a given criteria.
Read more >
Calculate values using data in table cells in Numbers on Mac
In Numbers on your Mac, insert formulas and functions into table cells to calculate sums, products, averages, minimums, maximums, and more.
Read more >
calc() - CSS: Cascading Style Sheets - MDN Web Docs
The calc() CSS function lets you perform calculations when specifying CSS property values. It can be used with , , , , ,...
Read more >
cuFFT API Reference - NVIDIA Documentation Center
cufftPlanMany() - Creates a plan supporting batched input and ... E.G. for two GPUs half of the X dimenson points, for all Y...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found