Posted: 23 Mar 2019 6:19 EDT Last activity: 25 Mar 2019 4:11 EDT
how to debug Strategy property-set component
In my strategy, there are multiple different components used. One of the component which is used as Property-Set components.
Ex: TotalAmount = .Amount * quantity.
On a clipboard and tracer .Amount shows = 15.55 and quantity is 6. While trying to see the value of TotalAmount in strategy reults, It shows 93.7000000000000000000001. I wanted to understand how this 15 digit decimal is derived.
I would assume both properties are doubles, so they can't be stored exactly, which then causes the multiplication to be slightly off the expected value. Storing them as bigdecimals should keep full precision.