You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Nice to read u again.
...
I use the eventsspy indicator, which is does not really indicate anything but allows to pass events, i am interested in tick's only. So my first method was to create the indicator handle only when entering a trade, because no trade, no ticks needed. Similar to Andreas approach.
Now considering my EA loads 28 charts without doing anything it is a relative memory hog per definition. IndicatorRelease() does not work in tester, so it can not be tested. The continues creation and releasing was giving me the same worries as Andreas.
Ok so yes that's a good situation to use IndicatorRelease(). If it's beneficial or not depends about your EA.
Ok so yes that's a good situation to use IndicatorRelease(). If it's beneficial or not depends about your EA.
For me it was to avoid the indicator to trigger the event for ticks i do not need. The event queue gets messed up when there is large tick volumes in short time span. IE my logic gets triggered on ticks not needed and not triggered on ticks i need on a frequent bases, essentially rendering it useless.
I still think it is the best solution to eliminate the (any) indicator if you do not use it. If alone for the sake of resources. However it does not work in tester (though it should, everyone will vote for faster back tests and or optimization).
I have since worked around this problem by managing the indicator status through global vars. The indicator is still loaded and running on all charts, all the time, but switched on or of when needed.
Still not ideal, it is the best solution i have found for multi currency/asset EA working on tick basis only, not using some timer construction to get the ticks.
Somehow i cant kick the feeling MT1234 was created with simple one pair trading in mind and MT5 did not change any in this regard.
For me it was to avoid the indicator to trigger the event for ticks i do not need. The event queue gets messed up when there is large tick volumes in short time span. IE my logic gets triggered on ticks not needed and not triggered on ticks i need on a frequent bases, essentially rendering it useless.
I still think it is the best solution to eliminate the (any) indicator if you do not use it. If alone for the sake of resources. However it does not work in tester (though it should, everyone will vote for faster back tests and or optimization).
I have since worked around this problem by managing the indicator status through global vars. The indicator is still loaded and running on all charts, all the time, but switched on or of when needed.
Still not ideal, it is the best solution i have found for multi currency/asset EA working on tick basis only, not using some timer construction to get the ticks.
Somehow i cant kick the feeling MT1234 was created with simple one pair trading in mind and MT5 did not change any in this regard.
And why not a timer ?
IMO one needs right tool for the right job, timer feels like using hammer to screw in a screw.
The Services does looks promising. I will wait patiently.
IMO one needs right tool for the right job, timer feels like using hammer to screw in a screw.
The Services does looks promising. I will wait patiently.
Hopefully soon, will be very interesting.
Will a later reload of the same indicator use the same memory Yes/No ?
Can i delete and ad it 20000 times without killing memory with buffers Yes/No ?
THNX ;-) (@ Alain: dnt worry it was a year ago, cool to have u here ur a GURU ;-))
Baumann Andrea:
Sorry Guys this is going to far for my understanding
Will a later reload of the same indicator use the same memory Yes/No ?
Can i delete and ad it 20000 times without killing memory with buffers Yes/No ?
Answer to both questions is : it depends.
Even using IndicatorRelease(), after a "while" if the indicator is not used (elsewhere), it will be completely removed from memory. We don't have information about this "while" (AFAIK).
So 2 possibilities :
1° Either you "reload" AFTER the indicator has been "completely removed from memory", then all will be recalculated.
2° You "reload" BEFORE, you will get an handle to the same indicator already in memory.
THNX ;-) (@ Alain: dnt worry it was a year ago, cool to have u here ur a GURU ;-))