Simple MQL4 Indicator to Boolean Variable Conversion

MQL5 Indikatoren Experten

Auftrag beendet

Ausführungszeit 13 Stunden
Bewertung des Kunden
good
Bewertung des Entwicklers
Thank you

Spezifikation

I have gotten an indicator called RVOL, which measures the relative volume of a symbol against the past days of trading.

This is currently an indicator format.

What I need is this converted into a bool / double that reflects the same value shown in the indicator.

To understand further.

1) Watch the video provided (zip file)

2) Have a look at the code

3) Have a read of the rest of the description.

Note: I need developers who are able to deliver on time so please only apply if you can complete this task


This the main indicator section of code:

void CalculateRelVolume(const int startBar, const int rates_total, const long& volume[])
{

   vol[startBar] = (double)volume[startBar];

   int i = startBar;
   if (i >= rates_total) i = rates_total - 1;
   for (; i > 0 && !IsStopped(); i--)
   {
         double curr_volume = (double)volume[i];
         double mean_volume = 0.0;         
         
                        for(int j = 1; j <= AveragingDays; j++) 
                        mean_volume += (double)volume[i + (j * BarsIn24Hours)]; 
         
                        mean_volume /= (double)AveragingDays;
         
                        //N.B. Value of 1.0 represents current vol is equal to average volume, 0.0-1.0 is below average, >1.0 is above average
         if(mean_volume>0)
                        vol[i] = curr_volume / mean_volume;            
         if(vol[i] > indicator_level1) volHigh[i] = vol[i];         //If current vol higher than average     
         else if (vol[i] > indicator_level2) volMedium[i] = vol[i];   //If current vol lower than average     
         else volLow[i] = vol[i];
   }
}

Note there are more parts to this indicator. But simple answer is vol[i] is the value that needs to be fetched.


This is my first attempt: (Note I do not want to have to fetch iCustom)


bool RVOL1(string symb1)
{
double RVOL = iCustom(symb1, PERIOD_M1,"RVOL", 5, 3, 1);

double RVOL_MAX = 1.0;

   if(RVOL < RVOL_MAX)
   return true;

   else
   {
   return false;
   }
   
   return false;
}


This is my second attempt at it:


   bool isVolumeBelowAverage(string symb) {
    
    bool state = false;
    int averagingDays = 5;
    
    int rates_total = Bars(symb, PERIOD_M1);
    int barsIn24Hours = 0;

    datetime prevDateTime = iTime(symb, PERIOD_M1, 0) - (86400 * 7);
    int numBarsIn7Days = iBarShift(symb, PERIOD_M1, prevDateTime, false);
    barsIn24Hours = numBarsIn7Days / 5;
    
    if (barsIn24Hours == 0) return false;
    
    double curr_volume = iVolume(symb, PERIOD_M1, 0);
    double mean_volume = 0.0;
    
    for (int j = 1; j <= averagingDays; j++) {
        mean_volume += iVolume(symb, PERIOD_M1, 0 + (j * barsIn24Hours));
    }
    
    mean_volume /= (double)averagingDays;
    double relVolume = 0.0;
    
    if (mean_volume > 0) {
        relVolume = curr_volume / mean_volume;
    }
    
    if(relVolume < 0.8)
    {
    state = true;
    }
    
    return(state) ;
}


Dateien:

ZIP
rvol.zip
6.8 Mb

Bewerbungen

1
Entwickler 1
Bewertung
(42)
Projekte
62
8%
Schlichtung
12
58% / 42%
Frist nicht eingehalten
1
2%
Frei
2
Entwickler 2
Bewertung
(254)
Projekte
573
36%
Schlichtung
64
20% / 58%
Frist nicht eingehalten
147
26%
Frei
Ähnliche Aufträge
Dear Developers, I would have a very simple request. I have a ML model developed in Python for EURUSD daily trading. I would like to backtest it in Meta Trader 5 using the Strategy Tester tool. For that I would need an Expert Advisor program. The input would be a csv file that contains two columns: - dates (going back for a few years on a daily basis) - trading signal (it can have only 2 values, either 1: Buy, or -1
Good day i will need a developer to create an EA for me using existing trading view indicator .The EA will open after the indicator has given signal and will close if altenate signal comes.The trading view indicator will be shared and improvement is welcome
Creating of an expert advisor or trading bot that uses a Top Down analysis (using monthly, weekly, daily, hourly, minutes ( 30, 15, 5, 1) to determine trade direction or trend direction and makes multiple trade decisions for mt4. You can use or combine accurate trend indicators
Creating of an expert advisor or trading bot that uses a Top Down analysis (using monthly, weekly, daily, hourly, minutes ( 30, 15, 5, 1) to determine trade direction or trend direction and makes multiple trade decisions for mt4. You can use or combine accurate trend indicators
Hello The EA will work on particular zone choose by the user and can mark it on any TF and with some rules can open trades and mange the trade by some unique rules. the EA need to check the difference by RSI as well and with some extra rules . developer should have good attitude and good communication (englsih) with high performence and knowledge with coding EA
I am looking forward to automate my trading strategy where I use renko bars on Tradingview. I really want to use unirenkos too, but unfortunately I couldn't figure out how to use ninjatrader on my MacBook and Tradingview does not offer unirenkos. As far as I see from your offered services you are very familiar with ninjatrader. I wanted to ask you if you could code me an Indicator for unirenkos for Tradingview so I
I am looking forward to automate my trading strategy where I use renko bars on Tradingview. I really want to use unirenkos too, but unfortunately I couldn't figure out how to use ninjatrader on my MacBook and Tradingview does not offer unirenkos. As far as I see from your offered services you are very familiar with ninjatrader. I wanted to ask you if you could code me an Indicator for unirenkos for Tradingview so I
Hello The EA will work on particular zone choose by the user and can mark it on any TF and with some rules can open trades and mange the trade by some unique rules. the EA need to check the difference by RSI as well and with some extra rules . developer should have good attitude and good communication (englsih) with high performence and knowledge with coding EA
Hello, I want to create an EA that can be able to take and optimise trade bids using the trend tracker concept I have developed. The tracker will monitor 2 lines to determine the trend of the market and afterwards take bids towards the correct direction. It will also be able to use a distance between the bids for the direction of the trend and plan a reverse bid when the price of the extreme doesn’t change again. The
Gradient boosting and L2 100 - 200 USD
I am looking for a well experienced programmer to put/implement a gradient boosting algorithm and an L2 to reduce overfitting in my ea which l already have which uses indicators . If you are experienced please adhere

Projektdetails

Budget
30+ USD
Für die Entwickler
27 USD
Ausführungsfristen
bis 1 Tag(e)