var someFloat = 0.123456789;
Number(someFloat.toFixed(4));
(Math.round(someFloat*10000)/10000);
FAQ: FAQ
Source code: GitHub/MeasureThat.net
Report issues: MeasureThat.net/Issues
Based on: Benchmark.js
Facebook page: https://www.facebook.com/MeasureThat.Net
Python benchmarks support: Pyodide