Hello,
I've created an oscillator that makes use of a couple of moving averages. I like the fact that (if I rem out setComputeOnClose()) the indicator dynamically reflects the current action synonymous with the current bar on the chart...(aka 'real time').
In other words as the 5 min bar is forming the oscillator (in turn) reflects that movement dynamically. The problem is, I've noticed that the moving averages don't paint - in the oscillator - accurately, unless I use setComputeOnClose(). I assume what is happening is that the oscillator is recording the price action just prior to the close...not the price action synonymous with the close itself. Thus looking at the chart after the fact, the oscillator (and it's moving averages) are in places not synonymous with the chart.
Is there any way of ensuring the price action of the close is included in the calculations of the oscillator while still allowing the oscillator to fluctuate 'real time' with the formation of the bar...without using setComputeOnClose()?
Any help is much appreciated,
gg
I've created an oscillator that makes use of a couple of moving averages. I like the fact that (if I rem out setComputeOnClose()) the indicator dynamically reflects the current action synonymous with the current bar on the chart...(aka 'real time').
In other words as the 5 min bar is forming the oscillator (in turn) reflects that movement dynamically. The problem is, I've noticed that the moving averages don't paint - in the oscillator - accurately, unless I use setComputeOnClose(). I assume what is happening is that the oscillator is recording the price action just prior to the close...not the price action synonymous with the close itself. Thus looking at the chart after the fact, the oscillator (and it's moving averages) are in places not synonymous with the chart.
Is there any way of ensuring the price action of the close is included in the calculations of the oscillator while still allowing the oscillator to fluctuate 'real time' with the formation of the bar...without using setComputeOnClose()?
Any help is much appreciated,
gg
Comment