TP BB haute

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #250402 quote
    paulPRTpaulPRT
    Participant
    Junior

    Bonjour,

     

    Je souhaiterai coder une stratégie qui achète si le prix touche la bollinger basse, qui met un SL sous le plus bas et un TP sur la bollinger haute.

    Le TP va donc changer à chaque période.

     

    Avez vous une idée de comment faire ?

     

    En vous souhaitant une très bonne journée

    #250407 quote
    JSJS
    Participant
    Master

    Salut,
    Essayez ces…

    DefParam CumulateOrders=False
    
    Period=20
    Mult=2 //2 * Standard Deviation
    SL=20 //StopLoss Points
    
    BollUp=Average[Period,0](Close)+Std[Period](Close)*Mult
    BollDown=Average[Period,0](Close)-Std[Period](Close)*Mult
    
    If Close crosses over BollDown then
    Buy 1 contract at Market
    Set Stop Price BollDown-SL
    Set Target Price BollUp
    EndIf
    
    If LongOnMarket then
    Set Stop Price BollDown-SL
    Set Target Price BollUp
    EndIf
    
    GraphOnPrice BollUp Coloured("Green")
    GraphOnPrice BollDown Coloured("Red")
    robertogozzi and Iván González thanked this post
    Scherm­afbeelding-2025-09-06-om-13.09.20.png Scherm­afbeelding-2025-09-06-om-13.09.20.png
    #250411 quote
    paulPRTpaulPRT
    Participant
    Junior

    Merci Beaucoup !

    JS thanked this post
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

TP BB haute


ProOrder : Trading Automatique & Backtests

New Reply
Author
author-avatar
paulPRT @paulprt Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by paulPRTpaulPRT
1 year, 2 months ago.

Topic Details
Forum: ProOrder : Trading Automatique & Backtests
Language: French
Started: 09/06/2025
Status: Active
Attachments: 1 files
ProRealCode ProRealCode
Loading...