amelioration PRT code avec RSI indicateur

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #87701 quote
    dztrader76
    Participant
    New

    bonjour

    je cherche a ajouter du code pour les ventes ????

    vous avez une idee spv?

     

     

    // Définition des paramètres du code
    DEFPARAM CumulateOrders = False // Cumul des positions désactivé

    // Conditions pour ouvrir une position acheteuse
    indicator1 = SMI[14,3,5](close)
    indicator2 = Average[3](SMI[14,3,5] (close))
    c1 = (indicator1 CROSSES OVER indicator2)

    indicator3 = close
    indicator4 = Average[20](close)
    c2 = (indicator3 >= indicator4)

    IF c1 AND c2 THEN
    BUY 1 CONTRACT AT MARKET
    ENDIF

    // Conditions pour fermer une position acheteuse
    indicator5 = SMI[14,3,5](close)
    indicator6 = Average[3](SMI[14,3,5](close))
    c3 = (indicator5 CROSSES UNDER indicator6)

    IF c3 THEN
    SELL AT MARKET
    ENDIF

    // Stops et objectifs
    SET STOP %LOSS 5

    #87706 quote
    swapping
    Participant
    Master
    // Définition des paramètres du code
    DEFPARAM CumulateOrders = False // Cumul des positions désactivé
    
    // Conditions pour ouvrir une position acheteuse
    indicator1 = SMI[14,3,5](close)
    indicator2 = Average[3](SMI[14,3,5] (close))
    c1 = (indicator1 CROSSES OVER indicator2)
    
    indicator3 = close
    indicator4 = Average[20](close)
    c2 = (indicator3 >= indicator4)
    
    IF c1 AND c2 THEN
    BUY 1 CONTRACT AT MARKET
    ENDIF
    
    // Conditions pour fermer une position acheteuse
    indicator5 = SMI[14,3,5](close)
    indicator6 = Average[3](SMI[14,3,5](close))
    c3 = (indicator5 CROSSES UNDER indicator6)
    
    IF c3 THEN
    SELL AT MARKET
    ENDIF
    
    // Stops et objectifs
    SET STOP %LOSS 5

    Voila le rendu avec le bouton [Insert PRT code] mais je n’ai pas la réponse, bonnes fêtes de fin d’année 😉

    #87711 quote
    dztrader76
    Participant
    New

    merci comme meme swapping

    #87712 quote
    robertogozzi
    Moderator
    Master

    Voilà:

    // Définition des paramètres du code
    DEFPARAM CumulateOrders = False // Cumul des positions désactivé
     
    // Conditions pour ouvrir une position acheteuse
    indicator1 = SMI[14,3,5](close)
    indicator2 = Average[3](SMI[14,3,5] (close))
    c1 = (indicator1 CROSSES OVER indicator2)
     
    indicator3 = close
    indicator4 = Average[20](close)
    c2 = (indicator3 >= indicator4)
     
    IF c1 AND c2 THEN
    BUY 1 CONTRACT AT MARKET
    ENDIF
     
    // Conditions pour fermer une position acheteuse
    indicator5 = SMI[14,3,5](close)
    indicator6 = Average[3](SMI[14,3,5](close))
    c3 = (indicator5 CROSSES UNDER indicator6)
     
    IF c3 THEN
    SELL AT MARKET
    ENDIF
    //
    //----------------------------------------------------------------------
    //  Vente
    indicator7 = SMI[14,3,5](close)
    indicator8 = Average[3](SMI[14,3,5] (close))
    c4 = (indicator7 CROSSES UNDER indicator8)
     
    indicator9  = close
    indicator10 = Average[20](close)
    c5 = (indicator9 < indicator10)
     
    IF c4 AND c5 THEN
    SELLSHORT 1 CONTRACT AT MARKET
    ENDIF
     
    // Conditions pour fermer une vente
    indicator11 = SMI[14,3,5](close)
    indicator12 = Average[3](SMI[14,3,5](close))
    c6 = (indicator11 CROSSES OVER indicator12)
     
    IF c6 THEN
    EXITSHORT AT MARKET
    ENDIF
    
     
    // Stops et objectifs
    SET STOP %LOSS 5
    swapping and Nicolas thanked this post
Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

amelioration PRT code avec RSI indicateur


ProOrder : Trading Automatique & Backtests

New Reply
Author
author-avatar
dztrader76 @dztrader76 Participant
Summary

This topic contains 3 replies,
has 3 voices, and was last updated by robertogozzi
7 years, 2 months ago.

Topic Details
Forum: ProOrder : Trading Automatique & Backtests
Language: French
Started: 12/28/2018
Status: Active
Attachments: No files
Logo Logo
Loading...