Login Page - Create Account

Support Board


Date/Time: Wed, 15 May 2024 15:49:16 +0000



ZF futures, Big problem using the function sc.TickSize

View Count: 1213

[2017-10-20 16:39:26]
User210074 - Posts: 63
Hello, I have a problem of comparison using the data of the function sc.TickSize ( ZF futures ).
I get the value in message log which is 0.007813 (ZF : sc.TickSize -> 0.007813)
I use this value in my function.
I can not understand what's going on.
I can not get the message "True"

/*....*/
float T = sc.TickSize;
if(T == 0.007813f){sc.AddMessageToLog("True", 1);}
else{sc.AddMessageToLog("False", 1);}
Ouput in message log : False.

I don't understand what 's happen !!!
[2017-10-20 17:26:27]
Sierra Chart Engineering - Posts: 104368
The actual tick size for this symbol is: .0078125

You also need to use this function for proper floating-point comparisons:

sc.FormattedEvaluate()
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account