4HR 5EMA Expert Advisor -
1 2 3 4 ...

thread: 4HR 5EMA Expert Advisor

  1. #11
    does it require some history until it will get a smiley face and the message at the upper left disappears. . I have checked let live trading etc.. .
    Yes it requires only five bars of history so that it's enough for the 5EMAs. Are you getting Trade or Not enough History not allowed in the upper left corner?

    If you see over five bars on the chart you shouldn't be getting that error? If you are then the problem might be with metatrader4. You might try removing the code
    Inserted Code if(Barslt;5 || IsTradeAllowed()==false) Comment(Not enough History or Trade not permitted ); return in the bottom at the MT4 editor.

  2. #12
    does it require some history before it gets a smiley face and the material in the top left disappears. . I've checked let live trading etc.. .
    I also only realized If your broker isn't letting trading it'll display that message too. For instance if it is after hours.

  3. #13
    Junior Member suboxrintt-71's Avatar
    12
    Thanks to Creating an EA. However, I have don't have any question concerning the spread and wondering if it would be better to use (Ask-Bid) instead of a fixed propagate?

  4. #14
    Junior Member gandano02's Avatar
    28
    Maxss280 thanks

    I only have to give it a couple more bars for Mr. Smiley to smile.

  5. #15
    I applied your EA's backup on friday and by morning it's developed a 700 USD to 2,500 USD it put orders on G/Y, E/J and G/U totalling to 2,500 USD.

    But I discovered that it couldn't close the prior positions when other new signal came.

    But because I've applied the altered one i.e. v5 it's not put a single order because yesterday.

    Pls test and lets understand how far.

    I cant wait to find that this EA become profitable on real acct.

    Maxss280 nicely done, I appreciate your attempt.

  6. #16
    1 Attachment(s)
    Thank You for making an EA. However, I have do have a question about the spread and wondering if it would be safer to use (Ask-Bid) instead of a fixed spread?
    Changes V1.6I have altered the spread to used the Ask-Bid which is the disperse price. Removed the Risk Management Feature (Normally caused more harm than good) Additional Spread to the HUD Thank you for the suggestion BullRun I think this will help on a live account.
    https://www.cliqforex.com/general-fo...day-trade.html

  7. #17
    @ Andrew
    Thank you for your remarks and I really do think you have some valid points.

    Reply
    1. I didn't notice he was adding some lol I will attempt to include those rules shortly.

    2. Yeah I discovered that was an ineffective bit of code that I did not wish to add another work around since I did not know how to code it. I shall use the code with the Time[0] that I was shown by you. Thank you for you help still studying MT4 language

    3. Yeah converting the Market Orders over to Pending orders may require a little thought as not to break the logic. When I first wrote this logic was different and the Market order is something that stuck around but it does need to be changed into a Pending order because you specified.

    Thanks

    Hello,

    I don't examine EA for the time being, however, take a look at source - it looks great - and have any remarks.

    1. It seems you don't apply additional rules from article 1 4H5EMA thread (1 to 3).

    2. Back in CheckForOpen() You compute both ema every tick - it isn't essential, it is sufficient to compute it once for 4H in something such as his


    if (Time[0]! ) =dtBarTime)
    dtBarTime=Timing [0];
    emaHigh = iMA(NULL,0,EMAPeriod,0,MODE_EMA,PRICE_HIGH,1);
    emaLow = iMA(NULL,0,EMAPeriod,0,MODE_EMA,PRICE_LOW,1);


    dtBarTime should be datetime and emaHigh and emaLow should be international var in this case.

    If You use just 1 EA it is not problem but if You use many of it it's important to maximize terminal use - it should be quicker in backtests too.

    3. You create commerce with market orders (except rev trade) it is okay but in fast market eg news, it could generate big slippage (terminal don't respond as quickly as brokers servers). It is not big problem but one should remember this especialy when analyzing system (sterling use stop orders). Employing Stop orders could be little more complied.

    Unfortunately I am very busy today but hope I'll find some time to try this EA possibly tomorow.

    I like this egy along with your job.

    Regards,

    Andrew

    P.S. Sorry for english, it is not my first language.

  8. #18
    @

    If I recall correctly I think V1.2 had any logic errors that made it not follow the rules properly. This could be exactly what caused the orders not final.

    I casually applied the v2 copy of your EA on friday and from monday morning it has developed a 700 USD to 2,500 USD it put orders G/U, E/J and G/Y totalling to 2,500 USD.

    But I discovered that it could not close the prior rankings when other new signal came.

    But because I've applied the modified one i.e. v5 it has not put one order because yesterday.

    Pls check and lets understand how far.

    I cant wait to find that this EA become profitable on actual acct.

    Maxss280 well done, I appreciate your attempt.

  9. #19
    Remove the EA version that is no longer valid i.e. the v2 and v.5 to ensure we would have same EA exactly the same result, this is to reduce confusion.

    Pls do so as you upgrade the EA, currently the valid new variant is v6

    good work

  10. #20
    That the 1600 candle has closed and it qualified as a pub that was setup, and there was a G/U short trade that the EA placed.

    If this EA is working with the principles sterling set then:
    I expect the EA to shut the preceding short position and start the long position but it did not do anything

    so friend look into this LOGIC very well

  •