Support Board
Date/Time: Mon, 07 Jul 2025 13:16:51 +0000
Post From: Rounding floats in spreadsheet
[2021-12-10 02:15:21] |
Sawtooth - Posts: 4236 |
Now J94 is returning a float despite being rounded to the rounded tick size.
With some prices and tick sizes, there are still floating point errors.This is another solution in those situations: Put this in H90, or any open static cell: =LEN(TEXT(1/ROUND(1/J21,0)))-1 this returns the number of decimal places of the rounded tick size. In H94: =ROUND(J94,H90) This is actually a more universal solution. |