Bid && Ask && Spread - page 7

 
Renat:
Average cannot be used, as it will give non-existent prices, which is fatal.
MathCeil(Average(...))
 
Renat:
The average can't, as it would give non-existent prices...
A reasonable argument.
 
The maximum will have the same effect in terms of fatality as the medium and openings.
 
hrenfx:
The maximum will have the same effect in terms of fatalities as the medium and the openings.
What to do...??
 

Go to pre-existing prices - add Ask. And forget the spread as a kitchen atavism forever.

OFFTOP:

Looking here. Who do you think is more profitable to trade with (under equal execution conditions), who has narrower spreads more often, or who's Bid is higher than others and Ask is lower?

You can evaluate trading conditions (with equal execution conditions) only by analyzing both prices, but not the spread. It is an illiterate myth that a narrow average, minimum or maximum spread says something about trading conditions.

 
hrenfx:
Go to the existing prices - add Ask. And forget about the spread as a kitchen atavism forever.

The question is what Ask to add?

  • The one at the opening of the minute bar?
  • The one at the moment of maximum spread in the minute bar?
  • Any other option.
 
OHLC Ask data is added. Ask and Bid become fully equal in information. Without equality, there is a serious bias.
 

hrenfx:
Добавляются OHLC Ask данные. Ask и Bid становятся полностью равноправными по информации. Без равноправия получается серьезный перекос

A simple example of how Ask price discrimination is affected by OHLC Bid + Avg Spread approach:

You have optimised your EA. You have put it on the real account. After a certain amount of trades, you will notice that the SELL-transactions are much more numerous than BUY-transactions when compared to the same ratio in the tester. This is the reason why the Bid price data in the tester is complete and the Ask is completely the opposite.

I don't understand how this bias is obtained (due to what). Does it only affect those experts who analyse every tick to make decisions? Maybe you have some simple test EA to study in more detail. Interesting, I just want to understand.

 
hrenfx:

... And forget about spread as a kitchen atavism forever.

...

But it's a concept nonetheless. And it is present in the link that you cited. So you can't forget.)))

 

Take a simple channel reversal strategy implemented on limiters:

  1. Let the centre of the channel be set as an MA and its width, let's say, fixed. In general, any channel you can think of.
  2. Cut inward on the channel border using limit orders. I.e., on the channel edges we simply place the corresponding Limit orders.

This is a simple strategy. Try it in the tester so that trades are executed more frequently and then run it with these parameters on a demo with a floating spread.

Then perform the following steps:

  1. Wait until the strategy makes at least a hundred (for statistics) trades.
  2. For the time interval that the system was working on the demo, run it in the tester.
  3. Compare the ratio of BUY and SELL trades in the tester and on the demo.

They will be different. This is because only two prices are very important for this strategy - High Bid and Low Ask. The tester data on High Bid will be accurate from history. But Low Ask - not, because it will be modelled = Low Bid + Spread.

Документация по MQL5: Стандартные константы, перечисления и структуры / Состояние окружения / Информация об инструменте
Документация по MQL5: Стандартные константы, перечисления и структуры / Состояние окружения / Информация об инструменте
  • www.mql5.com
Стандартные константы, перечисления и структуры / Состояние окружения / Информация об инструменте - Документация по MQL5