break out candela estesa

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #203376 quote
    Gabriele BattistaGabriele Battista
    Participant
    Senior

    Vorrei scrivere un trading system che entri long/short al break out di una candela estesa (esempio 35 punti) purchè avvenga nelle sole 2 candele successive. E’ possibile, grazie

    #203394 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Eccolo:

    ONCE EntrataLong  = 0
    ONCE EntrataShort = 0
    ONCE Barra        = 0
    IF Barra > 0 THEN
       Barra = Barra + 1
       IF Barra > 2 THEN
          Barra = 0
       ENDIF
    ENDIF
    Estesa          = range >= 50 * PipSize   //almeno 35 punti
    IF Estesa THEN
       Barra        = 1
       EntrataLong  = high + 1 * PipSize
       EntrataShort = low  - 1 * PipSize
    ENDIF
    IF OnMarket THEN
       EntrataLong  = 0
       EntrataShort = 0
       Barra        = 0
    ENDIF
    IF Barra > 0 THEN
       BUY       1 CONTRACT AT EntrataLong  STOP
       SELLSHORT 1 CONTRACT AT EntrataShort STOP
    ENDIF
    SET STOP   pLOSS   100
    SET TARGET pPROFIT 300
    #203397 quote
    Gabriele BattistaGabriele Battista
    Participant
    Senior

    grazie lo provo

    #203472 quote
    Gabriele BattistaGabriele Battista
    Participant
    Senior

    Mi da errore.

    #203474 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Vedo che non è formattato come il mio, penso sia incluso qualche carattere di controllo estraneo al codice.

    Importa il file ITF che allego.

    Il-Mio-Sistema.itf
    #203478 quote
    Gabriele BattistaGabriele Battista
    Participant
    Senior

    grazie ora non da più errore

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

break out candela estesa


ProOrder: Trading Automatico & Backtesting

New Reply
Summary

This topic contains 5 replies,
has 2 voices, and was last updated by Gabriele BattistaGabriele Battista
3 years, 10 months ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 11/01/2022
Status: Active
Attachments: 1 files
ProRealCode ProRealCode
Loading...