Equity indicator

MQL4 Indicators

Specification

Hi All,

I want to create an equity indicator similar to this one here : https://www.mql5.com/ru/code/8588

  1--The indicator should have  the correlation between the equity curve generated by a trading system and the "ideal" equity curve based on past N  trades .The ideal

equity curve based on equity curve of non repaintinting zigzag the idea from here  : http://www.breakoutfutures.com/Newsletters/Newsletter0605.htm

2-  The indicator will have the  Trade Equity Regression Trend Line Coefficient of Correlation for both past n trades AND open positions:  see the article  https://www.mql5.com/en/articles/1492   From the article ,I think below is the code of what I am looking for I am not too sure :

 

Sx=Summ{(X-M(X))^2}/N Sy=Summ{(Y-M(Y))^2}/N r=cov(X,Y)/(Sx* Sy)

where:
N - amount of trades (including the open trades);
X - Balance;
Y - linear regression;
M(X) - Balance mean value;
M(Y) - LR mean value. 

The threshold of  equity line deviation from a linear regression trend line  should be >0,6   for example Bobsley LR correlation 0,44  https://championship.mql5.com/2010/ru/users/bobsley/reports

3-The  indicator should have Profit Factor >2  threshold for both past N trades AND open positions.

4- The indicator should have the efficiency ratio of entry- exit    see Bulashev stats https://www.mql5.com/en/articles/137   and here https://championship.mql5.com/2010/en/news/42?source=terminal03.11.10

I think code part is here :

//+------------------------------------------------------------------+
//| calculation of effectiveness |
//+------------------------------------------------------------------+
void C_Pos::efficiency()
  {
   for(int i=0;i<count_trades;i++)
     {
      m_trades_stats[i].max_price_trade=iHighest(symbol,PERIOD_M1,m_trades_stats[i].enter_date,m_trades_stats[i].exit_date); // maximal price of trade
      m_trades_stats[i].min_price_trade=iLowest(symbol,PERIOD_M1,m_trades_stats[i].enter_date,m_trades_stats[i].exit_date);  // minimal price of trade
      double minimax=0;
      minimax=m_trades_stats[i].max_price_trade-m_trades_stats[i].min_price_trade;// difference between maximum and minimum
      if(minimax!=0)minimax=1.0/minimax;
      if(m_trades_stats[i].trade_type==DEAL_TYPE_BUY)

        {
         //Effectiveness of entering a position
         m_trades_stats[i].enter_efficiency=(m_trades_stats[i].max_price_trade-m_trades_stats[i].enter_price)*minimax;
         //Effectiveness of exiting from a position
         m_trades_stats[i].exit_efficiency=(m_trades_stats[i].exit_price-m_trades_stats[i].min_price_trade)*minimax;
         //Effectiveness of trade
         m_trades_stats[i].trade_efficiency=(m_trades_stats[i].exit_price-m_trades_stats[i].enter_price)*minimax;
        }
      else
        {
         if(m_trades_stats[i].trade_type==DEAL_TYPE_SELL)
           {
            //Effectiveness of entering a position
            m_trades_stats[i].enter_efficiency=(m_trades_stats[i].enter_price-m_trades_stats[i].min_price_trade)*minimax;
            //Effectiveness of exiting from a position
            m_trades_stats[i].exit_efficiency=(m_trades_stats[i].max_price_trade-m_trades_stats[i].exit_price)*minimax;
            //Effectiveness of trade
            m_trades_stats[i].trade_efficiency=(m_trades_stats[i].enter_price-m_trades_stats[i].exit_price)*minimax;
           }
        }
     }
  } 

  

Good clean fast code appriciated.Price negotiable 

 

 

 

Responded

1
Developer 1
Rating
(473)
Projects
1138
44%
Arbitration
51
31% / 33%
Overdue
500
44%
Free
2
Developer 2
Rating
(7)
Projects
17
18%
Arbitration
5
0% / 60%
Overdue
9
53%
Free
3
Developer 3
Rating
(71)
Projects
254
53%
Arbitration
16
50% / 38%
Overdue
83
33%
Free
Similar orders
I need a developer that can fix a indicator i have, I have a table that looks at emas and display bullish/bearish, I have spy on the table but its not always updating and need help fixing this I have this table and the first 6 rows looks at the chart symbol and if price is above 12 ema it will sows bullish under the 5/12 ema coulmn and bullish if its above, and same under the 34/50 colmun, if price is below 50 ema
I need a developer that can fix a indicator i have, I have a table that looks at emas and display bullish/bearish, I have spy on the table but its not always updating and need help fixing this I have this table and the first 6 rows looks at the chart symbol and if price is above 12 ema it will sows bullish under the 5/12 ema coulmn and bullish if its above, and same under the 34/50 colmun, if price is below 50 ema
I need an EA in MT5 that trades based on volatility with market orders. It must check and correctly process possible errors in trading operations. Entry and exits based on volatility threshold
Modificar EA 30+ USD
Es posible descompilar un EA de mt4? Tengo uno y me gustaría descompilarlo y poder tener el archivo haber como funciona de verdad. Saludos amigos programadores. espero tenga solución este problema
Hello, I am looking to have two custom indicators developed for integration into an Expert Advisor (EA): 1. Malaysian SNR (Support and Resistance) Indicator : This indicator should accurately identify and plot support and resistance levels based on Malaysian trading principles and methodologies. 2. Break of Structure Indicator : This indicator should detect and signal breaks in market structure, indicating potential
Hello Everyone, Herewith sending the existing Trading view Indicator, and required the same Indicator with all display into MT5. Trading view Indicator Screen shot attached for more reference. Price is negotiable
Hello there, I need a professional mt4 developer who can perfectly help me to backtest my mt4 trading strategy on these trading pairs, XAUUSD H1 PEPPERSTONE 1:200 LEVERAGE. The strategy would be provided once you bid to this task
GIOVA 30 - 50 USD
I need a skillful programmer that can Automate my trading indicator into an EA . System has 2 indicators. One of the Indicator is to know the Direction of Trend on H1 and the second indicator is to be use to enter trade on M5 in line with the H1 Trend The EA must have 1. TP and SL, 2. Trailing Stop Loss, 3. ability to add more trade when there is signal in line with H1
Hello, I am looking for a professional who can assist me with the following tasks: Create a used replica of my trading setup from TradingView. Copy and configure this setup in my Tradovate account. This is exactly what I need. Your assistance would be greatly appreciated this is exactly what i want https://youtu.be/WOMA8Ift9r8?si=PPf0CHNrZkZ0InHN
Hello, i need professionalthat can help me handle this, I want used replica to of my trading From trading view And copy to my tradovate this is exactly i need https://youtu.be/WOMA8Ift9r8?si=PPf0CHNrZkZ0InHN

Project information

Budget
50 - 60 USD
For the developer
45 - 54 USD