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
So this is my code above Fernando, what I mean is all is working fine, except it could take a trade signal on initialization, close that trade, skip one or 2 signals and then take the next trade on and on. Pls I would greatly appreciate your help
When you post code please use the CODE button (Alt-S)!
When you post code please use the CODE button (Alt-S)!
Gotcha! Thanks. Can anyone help? Or is this something we all deal with without knowing why?
maybe you forget that to open buy trades, they use Ask price, while the OHLC prices are Bid. Maybe what you think is a missed signal -- actually wasnt a signal.
maybe you forget that to open buy trades, they use Ask price, while the OHLC prices are Bid. Maybe what you think is a missed signal -- actually wasnt a signal.
I have a JPG screenshot where you see how it ended a trade, missed a clear signal which I circled and took the next one when the EA felt like it. Its not a matter of OHLC. This is strictly a sell bot, you can check the logic in the upper part of this thread
Help with your code can only be provided if you show all relevant code and explain the issue in detail. Otherwise, you will have to hire a freelance coder to do it for you.
I dropped the code and screenshots pls @Fernando Carreiro
I have a JPG screenshot where you see how it ended a trade, missed a clear signal which I circled and took the next one when the EA felt like it. Its not a matter of OHLC. This is strictly a sell bot, you can check the logic in the upper part of this thread
like i said previously. to open buy trades we use Ask price, but on the chart is always Bids only. You can not know that it was a signal if you do not know what the spread was at that time/moment.
In this case, that is irrelevant because the signal is only dependant on the bar data and it is placing an order at the current market price independent of spread.
Please note that this is regarding the code on post #10 and not the original poster.
At the start of a new bar, the current OHLC prices are all the same (Open = High = Low = Close).
So when you compare the High (or Low) of the previous bar with the Close of the current bar, you are actually comparing it with the Open Price of the current bar, not the Close. Only when the current bar completes will you know the final close price of the bar.
You probably meant to compare the previous bar's Close with the High/Low of the preceding bar (i.e. bar shift 2 and 1, not 1 and 0).
In this case, that is irrelevant because the signal is only dependant on the bar data and it is placing an order at the current market price independent of spread.
Please note that this is regarding the code on post #10 and not the original poster.
roger that.