Forum

How to stop automatic rounding up of input variables?

I'm trying to input a very small variable into an EA script: input double mVar = - 0.00001 ; However it is being rounded to -0.1; this is a significant problem. If I do not declare MyVar as an input variable the value obviously stays as is. What can I do to prevent this rounding? I haven't been able

Handle providing data in reverse order

I'm trying to use data from the MACD, and according to the documentation index [0] should contain the most recent data point. However I have found that the opposite is true. If I get three data points, [0] is the oldest whereas [2] is the most recent (changing on-tick as the price fluctuates). The

Retrieve Upper and Lower Bollinger Band values From iBand?

I'm trying to get the upper and lower values from iBand... void OnTick () { double upperBand[]; double lowerBand[]; double range; int handle = iBands ( _Symbol , _Period , 20 , 2 , 0 , PRICE_CLOSE ); // CopyBuffer(handle, which band, period, no. values, where to store)