End Of Day – YEN M15

End Of Day – YEN M15

Dear All,

Here is a simple strategy, a slight improvement of my “End of Day USD/JPY“.

The timeframe is M15.

The strategy is so simple that it doesn’t need explanations (see in the code).

You can adapt the parameters, so that you can use it on USD/JPY (the best), AUD/JPY, EUR/JPY, GBP/JPY.

Regards,

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

New! PRC is also now on YouTube, subscribe to our channel for exclusive content and tutorials

  1. Doctrading • 10 days ago #

    Here is a improvement with MOMENTUM.
    For M15 TIMEFRAME
    Thanks to a friend, “Calvin”.

    The performance is better :

  2. Doctrading • 10 days ago #

    // END OF DAY – YEN
    // http://www.doctrading.fr
    // + MOMENTUM (Calvin)

    Defparam cumulateorders = false

    // TAILLE DES POSITIONS
    n = 1

    // PARAMÈTRES
    // Plus le “ratio” monte, moins il y a de positions
    // USD/JPY : ratio = 0.4 / SL = 1 / TP = 0.8 / Period = 10

    ratio = 0.4

    // HORAIRES
    startTime = 210000
    endTime = 231500
    exitLongTime = 210000
    exitShortTime = 80000

    // INDICATEUR MOMENTUM

    OTa = Momentum[26]
    c1a = OTa > OTa[11]
    MLTa = Momentum[280]
    c2a = MLTa > MLTa[20]

    OTv = Momentum[4]
    c1v = OTv < OTv[5]
    MLTv = Momentum[180]
    c2v = MLTv = startTime and time <= endTime and dayOfWeek 5 and CONDBUY then
    buy n shares at ouverture – amplitude*ratio limit
    ENDIF
    if time >= startTime and time <= endTime and dayOfWeek 5 and CONDSELL THEN
    sellshort n shares at ouverture + amplitude*ratio limit
    endif

    // Stop Loss & Take Profit
    set stop %loss SL
    set target %profit TP

    // Exit Time
    if time = exitLongTime then
    sell at market
    endif
    if time = exitShortTime then
    exitshort at market
    endif

    • Nicolas • 10 days ago #

      Peut-être un poil sur-optimisé ? Une idée de la performance OOS ?

    • BobFlynn • 8 days ago #

      Hello,

      Problème de copié collé ici : c2v = MLTv = startTime
      Si je comprend bien on devrait pluto avoir c2v = MLTv > OTv ?

  3. Artemois • 10 days ago #

    Thank You for sharing.
    PRT v10.3 says : Syntax error line 34 char 58, it’s pointig at the 5 [dayOfWeek 5].
    Am I doing something wrong or is v11 needed ?
    Cheers!

  4. denottes • 10 days ago #

    Bonjour et merci pour le partage,
    Je n’arrive pas à exécuter le code avec le Momentum. J’ai une erreur de syntaxe. could y help 🙂 Thx

  5. Calvin Teddy • 9 days ago #

    Avec plaisir ! 😉
    Qu’entendez-vous par performance OOS Nicolas ?

    • Nicolas • 9 days ago #

      Hors échantillon, puisqu’il me semble que la stratégie a été optimisée sur tout l’historique ? Voir les vidéos sur l’optimisation avec walk forward dans le blog.

    • Calvin Clark • 23 hours ago #

      Ah je n’utilise jamais le Walk Forward c’est pour ça.

    • Nicolas • 6 hours ago #

      Attention à la suroptimisation dans ce cas ! Si c’était aussi simple.. 😉 Tu devrais regarder les vidéos du blog sur le walk forward, toujours vérifier la robustesse d’une stratégie, c’est la base, à minima sur 30% de données post optimisation ( hors échantillon ou Out Of Sample en anglais).

  6. pjanin972 • 8 days ago #

    bonjour Calvin,
    merci pour votre contribution, sur quel critère avez-vous définis les valeurs du momuntum.
    je souhaite l’adapter à mes stratégies, peut-on en discuter sur un forum ?

    • Calvin Clark • 23 hours ago #

      Bonjour pjanin972, c’est de l’optimisation.
      C’est ces paramètres qui ont le mieux marché durant le backtest.

  7. Doctrading • 5 days ago #

    Hi all
    Just a little optimization for USD/JPY M15.
    Nice performance since 2018, you can do what you want with it (as is it a little bit “optimized”)
    Profit factor > 3,5.
    Regards,

  8. Doctrading • 5 days ago #

    //———————————————-
    // Code principal : End Of Day – USD/JPY M15
    // http://www.doctrading.fr
    //———————————————-

    Defparam cumulateorders = false

    // TAILLE DES POSITIONS
    n = 1

    // PARAMÈTRES
    // Plus le “ratio” monte, moins il y a de positions
    ratio = 0.64

    // HORAIRES
    startTime = 210000
    endTime = 231500
    exitLongTime = 210000
    exitShortTime = 80000

    // INDICATEUR MOMENTUM
    OTa = Momentum[26]
    c1a = OTa > OTa[11]
    MLTa = Momentum[280]
    c2a = MLTa > MLTa[20]
    OTv = Momentum[4]
    c1v = OTv < OTv[5]
    MLTv = Momentum[180]
    c2v = MLTv = startTime and time <= endTime and dayOfWeek 5 and CONDBUY then
    buy n shares at ouverture – amplitude*ratio limit
    endif
    if time >= startTime and time <= endTime and dayOfWeek 5 and CONDSELL then
    sellshort n shares at ouverture + amplitude*ratio limit
    endif

    // Stop Loss & Take Profit
    set stop %loss SL
    set target %profit TP

    //set stop loss amplitude * ratioSL

    // Exit Time
    if time = exitLongTime then
    sell at market
    endif
    if time = exitShortTime then
    exitshort at market
    endif

  9. vcharlesc • 4 days ago #

    Hi Doctrading, Thanks for your code and there is error as follow! could you fix it?
    c2v = MLTv = startTime and time <= endTime and dayOfWeek 5 and CONDBUY then

  10. dannydarocha • 3 days ago #

    Hello guys, thanks for the code !

  11. patmge • 1 day ago #

    Hello guys, thanks !

  12. fifi743 • 22 mins ago #

    bonsoir ,
    @nicolas
    j’ai mis le TP = 100 et la un gros bug .
    il affiche gagnant alors quand on regarde de prêt il est perdant et il touche le TP .
    position buy et le TP est en dessous de entrée

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar
Related users ' posts
juanj @zebra would you be so kind as to post your latest 4H USD/JPY results here: https://www.pror...
Holy Grail Thank you juanj for sharing this code, Backtests looks great in USDJPY and Crude Oil Is a...
juanj @Holy Grail, glad you like it. Would you perhaps mind sharing your results here: https://www...
Francesco78 Hi Pepmartorell, please let's continue the discussion on the forum thread so that we can sha...
Francesco78 Hi Pepmartorell, please let's continue the discussion on the forum thread so that we can sha...
Jusmih1 Hi there, i am looking at your Strategy however when you put in automatic trading mode its ...
GraHal Hi Pascal There's lots not clear to me! :) Are you referring to C1 = PARABOLIC>HIGH //R...
volpiemanuele hi, can I have the latest full code of this strategy ? Thansk
Steve Hey Grizzly, I know this probably doesn't belong to this post, however, don't know how else ...
Doctrading Sorry for the mistakes... My "Copy - Paste" did'nt work properly. Defparam cumulateorders...
Doctrading Hi all, Here is the new version, which is better :
Doctrading Defparam cumulateorders = false n=1 // Plus le "ratio" monte, moins il y a de positions ...

Top