Does anybody know, on an EA, how to get on a math operation ( substraction to be specific) only positive numbers? I am running into the problem that, for example, when the open price less than the close price, and the open price is smaller, the result is negative. I need this result to be positive, on other words, I need to substract ALWAYS the bigger price from the smaller price. Again, if someone knows how to do this, and is willing to share, that would be great. Thank you
Thanks to all for the answer. I do not think the multipling by -1 will do as this will only work if the result is negative, however, what is the result is positive? then, the multiplication's result would be negative
HIGH RISK WARNING: Foreign exchange trading carries a high level of risk that may not be suitable for all investors.
Leverage creates additional risk and loss exposure. Before you decide to trade foreign exchange, carefully consider your investment objectives, experience level, and risk tolerance.
You could lose some or all of your initial investment. Do not invest money that you cannot afford to lose. Educate yourself on the risks associated with foreign exchange trading, and seek advice from an independent financial or tax advisor if you have any questions.
Any data and information is provided 'as is' solely for informational purposes, and is not intended for trading purposes or advice.
Past performance is not indicative of future results.