Damned Martin - page 7

 
Ivan Butko:
In the log:
Core 1 tester stopped because OnInit failed

***

So you are working on a netting account. And you need to open a hedge account:The MetaTrader 5 trading platform has got hedging.

Ivan Butko:
***

By the way, if I just dumped to data folder from program - EA is not seen. Only if you compile the editor, then he saw

That's right, you have to compile. And you don't need to dump anything anywhere:

  1. Click on the file in the forum post - the browser starts downloading
  2. Click on the downloaded file - this file will be automatically opened in MetaEditor.
  3. Compile.
 
Need to throw in a kodobase already 😉. What do you call it? New Martin?
 
Vladimir Karputov:
Need to throw in the kodobase already 😉. What do you call it? New Martin?

damn Martin

)

 
Vladimir Karputov:
You should already be throwing in a kodobase 😉. What do you call it? New Martin?
MArtini
 
Renat Akhtyamov:

damn Martin

)

I didn't get it right away :-D))))))
 
No swear words or dirty words! CalledNew Martin in general (have to wait for publication).
 
Vladimir Karputov:
No swear words or dirty words! Anyway, calledNew Martin(need to wait for publication).
Vladimir, is the EA fully compliant with the TOR in the thread? Everything is clear, everything has been implemented?

Have you implemented something of your own? Your own ideas, developments
 
Ivan Butko:
Vladimir, does the Expert Advisor fully comply with the TOR in the topic? Everything is clear, everything has been implemented?

Have you implemented anything of your own? Your ideas, developments

It's easier for me to describe what my code does:

Based on the"Damned Martin"theme.

New Martin is an EA that opens two opposite positions when it starts. ProcessOnTradeTransaction. When Take Profit triggered, it opens a position (ONE) in the same direction. Intersection of two indicators Moving Average (Moving Average, MA, "Mashki") - this is a signal to open a larger lot position.

At the start we open two oppositely directed positions.

Then we wait for the TakeProfit triggering (OnTradeTransaction processing):

  • if a BUY position has been closed - then we open (now only one) BUY position
  • if a SELL position was closed, it means we open (now only one) SELL position.

New Martin algorithm

We have a losing position.

Try to fight it this way: wait for the moving average (MA) crossing

New Martin crossing

and open a position in the same direction as the losing position, but with a larger lot.

The balance increases, but the funds do not.

The chosen method is as follows: in the input parameters there is a percentage value of lagging behind the balance ("Loss persent"). It is calculated as:

New Martin formula


As you can see, there are no pair closes, if equity lags behind the balance by a certain percentage, we simply close all positions and start over: two positions...

 
Vladimir Karputov:

It's easier for me to describe what my code does:

Based on the"Damned Martin"theme.

New Martin is an EA that opens two opposite positions when it starts. ProcessOnTradeTransaction. When Take Profit triggered, it opens a position (ONE) in the same direction. Intersection of two indicators Moving Average (Moving Average, MA, "Mashki") - this is a signal to open a larger lot position.

At the start we open two oppositely directed positions.

Then we wait for the TakeProfit triggering (OnTradeTransaction processing):

  • if a BUY position has been closed - then we open (now only one) BUY position
  • if a SELL position was closed, it means we open (now only one) SELL position.


We have a losing position.

Try to fight it this way: wait for the moving average (MA) crossing


and open a position in the same direction as the losing position, but with a larger lot.

The balance increases, but the funds do not.

The chosen method is as follows: in the input parameters there is a percentage value of lagging behind the balance ("Loss persent"). It is calculated as:



As you see no paired closes - if funds lag behind the balance by a certain percentage - simply close all positions and start again: two positions...

Last request:

Please do a test over the last year or two with an initial deposit of $100 and post a picture in the thread.
 
Vladimir Karputov:

The balance is increasing, but the funds are not.

The method chosen is as follows: in the input parameters there is a percentage of funds lagging behind the balance ("Loss persent"). It is calculated as:

As you see, there are no pair closures - if funds lag behind the balance by a certain percentage, simply close all positions and start over: two positions...

Brilliant.

So you added your own after all.