## Remove digits representing irrelevant precision from a number with JavaScript

I’m looking for a function in Javascript (or JQuery) to remove digits representing irrelevant precision from a number. I’m calculating an estimated probability, and it could be a range of values – and …