Is there a need for a lock in MT5? - page 68

 
religare >>:

Для подбора прибыльных параметров.


You don't need your parameters.

Specify any and the result of the experiment with lokeless will show you that the same can be obtained without resorting to lokas.

the same, no matter what

 
Mischek >>:


Да не нужны Ваши параметры

Укажите любые и результат эксперимента перехода на безлок, покажет Вам что тоже самое можно получить не прибегая к локам

ТОЖЕ САМОЕ, не важно что

Good. Just going to make a correction to the code. It works with an error, although it is profitable.

 
religare >>:

Добро. Только внесу исправления в код. Он работает с ошибкой, хотя и прибыльно.

Then, be sure to keep the current edition. :)

 
getch писал(а) >>
How can such a simple situation be resolved without a loca?

Choose a DC where minlotsize<=lotstep. To open, for example, 1.05 to work with 0.05 is not through the arse? Yes, and there will be overhead costs. And the situation described above is unlikely to be attributed to the case where profit is obtained by lock.

I personally, too, am more comfortable with lots in some cases than with net position, but lots do not add profit to me.

By the way, consider your example from the brokerage company side: brokerage company is good, not a cook (why do we need a "bad" one?) it has a min lot 0.1 and you want to buy 0.05. Let's buy 0.15 and sell 0.1. How to deal with DT? The minimum that he can bridge from the counterparty 0.1, so this is the minimum lot that is exposed, it means that he needs to withdraw both of your positions, and therefore any easing of margin requirements is out of the question, and the spread may have to give in the full volume. I.e. having paid costs for working with 0.25, we work with 0.05, and it turns out we increase spread, bound "margin" by 5 times... Of course, this is very primitive and simplified view of the situation from that side, I am not able to do more, but something like that probably should work out...

 
Figar0 >>:

Выбрать ДЦ, где minlotsize<=lotstep. Открыться, например, 1,05 чтобы работать с 0,05 не через зад ли это? Да и накладные издержки будут. Ну и описаную ситуацию вряд ли можно отнести к случаю, где прибыль получается за счет лока.

Лично мне с локами тоже удобнее в некоторых случаях, чем с нетто позицией, но локи профита мне ну никак не добавляют.

Wrote above why brokers have problems introducing small lots. You know the disadvantages of working with kitchens yourself.

Locking itself, of course, cannot make a profit, which follows from primary schools arithmetic.

 
getch писал(а) >>

Of course, locking itself cannot make a profit, which follows from primary schools arithmetic.

Unfortunately, for some reason it is not clear to all (maybe skipped primary schools?) Therefore, a branch of a swelling before our eyes and does not sink).

 
Figar0 >>:

З.Ы. Кстати если рассмотреть Ваш пример со стороны ДЦ: ДЦ хороший, не кухня, (зачем нам "плохой"?) мин лот у него пусть 0.1, а вы хотите купить 0.05. Покупаем 0.15 и продаем 0.1. Как быть ДЦ? Минимум что он может перекрыть у контрагента 0.1, потому и такой минимальный лот выставлен, значит ему надо вывесть обе Ваши позиции, а значит не о каком смягчение маржинальных требований речи быть не может, да и спреды скорее придется отдать в полнолм объеме. Т.е. оплатив издержки на работу с 0.25 работаем с 0.05, и получается увеличиваем себе спред, связаную "маржу" в 5 раз... Конечно это совсем примитивное и упрощеное рассмотрение ситуации с той стороны, на большее я не способен), но где-то что-то так возможно и должно получиться...

There will always be a softening of margin requirements when withdrawing both ways. I have tried to describe it in detail here using a simple example.

Usually you would not need to open with 0.05 lot of 0.1 lot, for example. It usually happens like this:

we should open an SELL position for 9.55, and we cannot do that in the netting approach, because we already have a BUY position for 9.6. If we didn't have that BUY, we would open without any problems. It is strange that we should analyse already opened positions to open a netting approach. But it is true.

The netting system must be well thought out, especially when it is imposed.

 
getch >>:

Написал выше, почему у брокеров возникают проблемы с введением мелких лотов. Минусы работы с кухнями вы сами знаете.

Само локирование, конечно, прибыль дать не может, что следует из арифметики начальных классов школы.

(1) sell 0.1 - (2) buy 0.2 - (3) sell 0.4 - (4) buy 0.8 - (5) sell 0.16

Not from arithmetic, but from probability theory:

Suppose each order has a stop and a take. We open a (1) order and a pending order (2) at the distance of a "distance". The Take of the next order overlaps the Stop of the previous order to reach a profit.

50%/50% probability that a take (1) order will trigger

25%/25% probability that (2) order will be closed

probability of (3) orders 12.5/12.5

probability of take (4) orders 6.25/6.25

probability of take (5) orders 3.12/3.12

probability of stop (5) orders 3.12/3.12

Thus, the probability of the stop triggering is 3.12%. Take a certain value of distance, for example 200 pip, and calculate how often the stop (5) of the order will trigger and its value in comparison with the profit of previous options. According to my calculations, the profit/loss ratio is 4/1. Of course, this is the simplest calculation method; we have to also take into account take profit and stop size and their relation to the distance. But mathematically with rather complicated calculations the profitability is 1.5-2/1.



Figar0

I have a question, how will you be able to handle my EA if it has several blocks. Example:

30 min

open sell 0.1

on the next bar

open buy 0.1

etc. on every bar. Each open order is accompanied by its opposite double pending order at a distance.

If according to your theory you can do without a lock, then before the opening of the 1st order of the 2nd block you will have to close the 1st order of the 1st block?

I can imagine it is possible to close orders inside a block before opening a doubled opposite one, but how to do it if there are several blocks?

 
religare >>:

(1) sell 0.1 - (2) buy 0.2 - (3) sell 0.4 - (4) buy 0.8 - (5) sell 0.16

Из арифметики нет, а вот из теории вероятности:

предположим у каждого ордера есть стоп и тейк. Открывается (1) ордер, к нему отложенник (2) на расстоянии "дистанция". Тейк следующего ордера перекрывает стоп предыдущего так, чтобы в итоге был профит.

вероятность, что сработает тейк (1) ордера 50%/50%

вероятность, что сработает тейк (2) ордера 25%/25%

вероятность, что сработает тейк (3) ордера 12,5/12,5

вероятность, что сработает тейк (4) ордера 6,25/6,25

вероятность, что сработает тейк (5) ордера 3,12/3,12

вероятность, что сработает стоп (5) ордера 3,12/3,12

Таким образом вероятность того, что сработает стоп 3,12%. Возьмите определенное значение дистанции, например 200 pip и посчитайте как часто будет срабатывать стоп (5) ордера и его величину в сравнению с прибылью предыдущих вариантов. По моим расчетам соотношение прибыльность/неприбыльность - 4/1. Естественно, это самый примитивный способ расчета, надо учитывать еще и размер тейка, стоп и соотношение их с дистанцией. Но математически при довольно непростых расчетах возможна прибыльность 1.5-2/1.



Figar0

У меня возник вопрос, как Вы сможете разрулить мой советник, если у него несколько блоков. Пример:

30-минутки

открывается sell 0.1

на следующем баре

открывается buy 0.1

и т.д. на каждом баре. К каждому открытому ордеру - его противоположный удвоенный отложенник на расстоянии дистанции.

Если по Вашей теории можно обойтись без лока, то перед открытием 1-го ордера 2-го блока Вы вынуждены будете закрыть 1-й ордер 1-го блока?!

Я могу представить, что внутри блока можно закрывать ордера перед открытием удвоенного противоположного, но как сделать, если несколько блоков?









Have you already given the EA a remodel ?
 
It is being finalised. I don't see how it can be changed so that there are no locks.
Reason: