Stratégie avec différence par rapport prix d'ouverture

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #102267 quote
    LifenLifen
    Participant
    Senior

    Bonjour à tous,

    Je vous remercie d’avance de bien vouloir m’aider à programmer la stratégie suivante :

    Time frame 5 mn

    On considère le démarrage de la stratégie à 8h.

    Si le prix durant la séance est < 100 points par rapport au prix d’ouverture de 8h, alors j’achète 1 contrat au marché

    #102285 quote
    NicolasNicolas
    Keymaster
    Legend

    Pas de takeprofit, ni de stoploss ? 1 seul ordre par jour uniquement ?

    #102287 quote
    LifenLifen
    Participant
    Senior

    Bonsoir Nicolas,

    Si S/L et T/P.  oui partons sur un seul ordre par jour. Par contre, si l’on peut mettre un stop suiveur et breakeven ?

    Mettons S/L à 30 et T/P à 30

    Merci pour ton aide.

    #102602 quote
    LifenLifen
    Participant
    Senior

    Bonjour Nicolas,

    Je me permets de revenir sur ma demande de codage :

    Time frame 5 mn

    On considère le démarrage de la stratégie à 8h.

    Si le prix durant la séance est < 100 points par rapport au prix d’ouverture de 8h, alors j’achète 1 contrat au marché

    Pour S/L et T/P, je sais coder.

    Merci pour ton aide par avance.

    #102607 quote
    NicolasNicolas
    Keymaster
    Legend

    Pas de soucis, voilà le code de cette stratégie de trading :

    defparam cumulateorders=false
    
    if time=080000 then 
    buylevel=close-100*pointsize
    traded=0
    endif 
    
    if onmarket then 
    traded=1
    endif
    
    if not onmarket and not traded then 
    buy 1 contract at buylevel limit 
    endif
    
    set target pprofit 30
    set stop ploss 30
    
    
    
    #102613 quote
    LifenLifen
    Participant
    Senior

    Merci infiniment Nicolas pour ta réactivité.

    Bon après-midi

Viewing 6 posts - 1 through 6 (of 6 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

Stratégie avec différence par rapport prix d'ouverture


ProOrder : Trading Automatique & Backtests

New Reply
Author
author-avatar
Lifen @lifen Participant
Summary

This topic contains 5 replies,
has 2 voices, and was last updated by LifenLifen
7 years, 4 months ago.

Topic Details
Forum: ProOrder : Trading Automatique & Backtests
Language: French
Started: 07/09/2019
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...