Hello,
I have this linecode for setting the lot amount:
double Lot = eq/bidBar.getOpen()/1000*prc/100;
which give not rounded lots amount (for example 0.0023 or 0.0452, etc.)
How can I have round lots amount (with a leverage 2)
for example
if equity=0.01053 lot= 0.02 (rounded equity*2)
if equity=0.01103 lot= 0.022
if equity=0.01199 lot= 0.022
if equity=0.01201 lot= 0.024
Do I have to use something like round.math() or something else?
Thank you