Oslo,Norway
Experience: Intermediate
Platform: NinjaTrader
Trading: EUR/USD
Posts: 66 since Apr 2011
Thanks Given: 4
Thanks Received: 52
|
The function that got me started on this, was actually ill written, to some extent, and I could have managed without the array (in that case I put values into it in the wrong order).
So when I was testing the XAverage_a I just made a copy of the price numeric series copying the data into the array for test purposes; and hence getting the 0..N order with 0 being the last. I can see that the normal use of arrays would be to append values at the end of the array at each bar and that would require your function to calc EMA over it.
|