dax 50 strategia

Viewing 15 posts - 1 through 15 (of 20 total)
  • Author
    Posts
  • #229945 quote
    Francesco Rossi
    Participant
    New

    qualcuno può aiutarmi a tradurre questo codice per renderlo automantico ,grazie
    Trading System : dax 50
    Parametri da inserire manualmente dal trade
    1) Trend (up/down)
    2) Start level
    3) Box (ampiezza movimento e livello di stop loss /profit)
    Quindi :
    trend UP
    se last price <= start level-box allora sell 1 contract set target profit + 50 set stop ploss -50 se last price >= start level +50 allora NEW start level = start level+ 50 (TRAILING START)
    trend DOWN
    se last price >= start level + box allora buy 1 contract
    set target profit +50
    set stop ploss -50
    se last price <= start level – 50 allora New start level = start level -50 (TRAILING START)

    #229948 quote
    robertogozzi
    Moderator
    Master

    Pubblica il tuo argomento nel forum corretto:
    _ Supporto piattaforma ProRealTime: solo problemi relativi alla piattaforma.
    _ ProOrder: solo argomenti su strategie.
    _ ProBuilder: solo argomenti su indicatori.
    _ ProScreener: solo argomenti su screener.
    _ Discussione generale di Trading: qualsiasi altro argomento di trading.
    _ Benvenuto ai nuovi membri: per permettere ai nuovi membri del forum di presentarsi.

    Grazie 🙂

    L’ho spostato io nel forun corretto.

    Ecco la strategia:

    Trend     = 1         //1=UP, -1=DOWN
    StartLevl = 16000
    Box       = 50
    IF Trend = 1 THEN      //UP
       IF close <= (StartLevel - Box) THEN
          SELLSHORT 1 CONTRACT AT MARKET
          SET TARGET PRICE close - 50*PipSize
          SET STOP   PRICE close + 50*PipSize
       ENDIF
    ELSIF Trend = -1 THEN  //DOWN
       IF close >= (StartLevel + Box) THEN
          BUY 1 CONTRACT AT MARKET
          SET TARGET PRICE close + 50*PipSize
          SET STOP   PRICE close - 50*PipSize
       ENDIF
    ENDIF
    // trailing start
    IF LongOnMarket THEN
       IF close <= (StartLevel - 50) THEN
          StartLevel = StartLevel - 50*PipSize
       ENDIF
    ELSIF ShortOnMarket THEN
       IF close >= (StartLevel + 50) THEN
          StartLevel = StartLevel + 50*PipSize
       ENDIF
    ENDIF
    #230000 quote
    Francesco Rossi
    Participant
    New

    Buongiorno,

    grazie per la cortese risposta. Ho due problemi però :

    1. il sistema entra solo per posizioni long
    2. il codice non riconosce la scala di ingresso (in questo caso 50 punti) quindi va a mercato alle 9:00 invece che attendere il valore di ingresso multiplo di 50
    #230001 quote
    Francesco Rossi
    Participant
    New

    // Definizione dei parametri del codice
    DEFPARAM CumulateOrders = False // Posizioni cumulate disattivate
    // Il sistema cancellerà tutti gli ordini in attesa e chiuderà tutte le posizioni a 0:00. Dopo l’orario “Flat Before” non saranno piazzati nuovi ordini o posizioni.
    DEFPARAM FLATBEFORE = 090000
    // Cancellare tutti gli ordini in attesa e chiudere tutte le posizioni all’orario “Flat After”
    DEFPARAM FLATAFTER = 123000

    // Impedisce al sistema di tradare in giorni specifici della settimana
    daysForbiddenEntry = OpenDayOfWeek = 6 OR OpenDayOfWeek = 0
    trend = -1 // 1=UP, -1=DOWN
    StartLevl = 17900
    Box = 50
    if not onmarket then
    IF Trend = 1 THEN //UP
    IF close <= (StartLevel – Box) THEN
    SELLSHORT 1 CONTRACT AT MARKET
    SET TARGET PRICE close – 50*PipSize
    SET STOP PRICE close + 50*PipSize
    ENDIF
    ELSIF Trend = -1 THEN //DOWN
    IF close >= (StartLevel + Box) THEN
    BUY 1 CONTRACT AT MARKET
    SET TARGET PRICE close + 50*PipSize
    SET STOP PRICE close – 50*PipSize
    ENDIF
    ENDIF
    // trailing start
    IF LongOnMarket THEN
    IF close <= (StartLevel – 50) THEN
    StartLevel = StartLevel – 50*PipSize
    ENDIF
    ELSIF ShortOnMarket THEN
    IF close >= (StartLevel + 50) THEN
    StartLevel = StartLevel + 50*PipSize
    ENDIF
    ENDIF
    // Stop e target
    SET STOP pLOSS 50//trailing 100
    SET TARGET pPROFIT 50
    ENDIF

    #230048 quote
    robertogozzi
    Moderator
    Master

    Per Long o Short devi variare tu il parametro TREND, mettendo 1 se è al rialzo o -1 se pè al ribasso.

    Hai specificato di inserire i dati manualmente per poi automatizzare le entrate.

    Puoi crearti due copie della setssa strategia, dove su una metti il valore 1 e sull’altrea il valore -1.

    Per l’arrore di entrata sui 50 punti, indicami lo strumento ed il time frame usato, con l’ora della candela di entrata di un’operazione sbagliata.

    #230071 quote
    Francesco Rossi
    Participant
    New

    per il momento funziona in back test solo lo indicando trend -1 . con il trend 1 non ho risultati in back test

    uso lo strumento dax index time frame 1 secondo. tutte le operazioni entrano alle 9 ed eseguono solo posizioni andando a mercato

    #230073 quote
    robertogozzi
    Moderator
    Master

    Alega il file ITF che hai usato.

    #230079 quote
    Francesco Rossi
    Participant
    New

    // Il sistema cancellerà tutti gli ordini in attesa e chiuderà tutte le posizioni a 0:00. Dopo l’orario “Flat Before” non saranno piazzati nuovi ordini o posizioni.
    DEFPARAM FLATBEFORE = 090000
    // Cancellare tutti gli ordini in attesa e chiudere tutte le posizioni all’orario “Flat After”
    DEFPARAM FLATAFTER = 123000

    // Impedisce al sistema di tradare in giorni specifici della settimana
    daysForbiddenEntry = OpenDayOfWeek = 6 OR OpenDayOfWeek = 0
    trend = -1 // 1=UP, -1=DOWN
    StartLevl = 17900
    Box = 50
    if not onmarket then
    IF Trend = 1 THEN //UP
    IF close <= (StartLevel – Box) THEN
    SELLSHORT 1 CONTRACT AT MARKET
    SET TARGET PRICE close – 50*PipSize
    SET STOP PRICE close + 50*PipSize
    ENDIF
    ELSIF Trend = -1 THEN //DOWN
    IF close >= (StartLevel + Box) THEN
    BUY 1 CONTRACT AT MARKET
    SET TARGET PRICE close + 50*PipSize
    SET STOP PRICE close – 50*PipSize
    ENDIF
    ENDIF
    // trailing start
    IF LongOnMarket THEN
    IF close <= (StartLevel – 50) THEN
    StartLevel = StartLevel – 50*PipSize
    ENDIF
    ELSIF ShortOnMarket THEN
    IF close >= (StartLevel + 50) THEN
    StartLevel = StartLevel + 50*PipSize
    ENDIF
    ENDIF
    // Stop e target
    SET STOP pLOSS 50//trailing 100
    SET TARGET pPROFIT 50
    ENDIF

    #230123 quote
    robertogozzi
    Moderator
    Master

    Modifiche le seguenti due righe come segue:

    StartLevel = 17900
    Box        = 50*pipsize

    nella prima il nome era errato, nella seconda è opportuno aggiungere *PipSize, anche se con il DAX è ininfluente.

    #230183 quote
    Francesco Rossi
    Participant
    New

    come faccio per dire al sistema di eseguire una sola operzione al giorno ,cioè una sola posizione long o una short?

    #230188 quote
    Francesco Rossi
    Participant
    New

    non mi riconosce il segnale di trailing start .

    es: se il prezzo continua a salire non si aggiorna il livello d’ingresso short

    #230241 quote
    Francesco Rossi
    Participant
    New

    non riesco a sistemare il trailing start, può aiutarmi cortesemente?

    #230282 quote
    robertogozzi
    Moderator
    Master

    Questa versione lo aggiorna, ma non è facile fare le prove, perché è molto difficile che si verifchino:

    // Il sistema cancellerà tutti gli ordini in attesa e chiuderà tutte le posizioni a 0:00. Dopo l’orario "Flat Before" non saranno piazzati nuovi ordini o posizioni.
    //DEFPARAM FLATBEFORE = 090000
    // Cancellare tutti gli ordini in attesa e chiudere tutte le posizioni all’orario "Flat After"
    //DEFPARAM FLATAFTER = 123000
    
    // Impedisce al sistema di tradare in giorni specifici della settimana
    daysForbiddenEntry = OpenDayOfWeek = 6 OR OpenDayOfWeek = 0
    ONCE trend = -1 // 1=UP, -1=DOWN
    ONCE StartLevel = 17900
    ONCE Box        = 50*pipsize
    if not onmarket then
    IF Trend = 1 THEN //UP
    IF close <= (StartLevel - Box) THEN
    SELLSHORT 1 CONTRACT AT MARKET
    SET TARGET PRICE close - 50*PipSize
    SET STOP PRICE close + 50*PipSize
    ENDIF
    ELSIF Trend = -1 THEN //DOWN
    IF close >= (StartLevel + Box) THEN
    BUY 1 CONTRACT AT MARKET
    SET TARGET PRICE close + 50*PipSize
    SET STOP PRICE close - 50*PipSize
    ENDIF
    ENDIF
    ENDIF
    // trailing start
    IF LongOnMarket THEN
    IF close <= (StartLevel - 50*PipSize) THEN
    StartLevel = StartLevel - 50*PipSize
    ENDIF
    ELSIF ShortOnMarket THEN
    IF close >= (StartLevel + 50*PipSize) THEN
    StartLevel = StartLevel + 50*PipSize
    ENDIF
    ENDIF
    // Stop e target
    SET STOP   pLOSS   50
    SET TARGET pPROFIT 50
    
    #230397 quote
    Francesco Rossi
    Participant
    New

    buongiorno,

    ho fatto le prove ma purtroppo continua a non aggiornarsi il livello di ingresso (trailing start) . questo è il codice di prova che ho inserito

    // Impedisce al sistema di tradare in giorni specifici della settimana
    daysForbiddenEntry = OpenDayOfWeek = 6 OR OpenDayOfWeek = 0
    ONCE trend = 1 // 1=UP, -1=DOWN
    ONCE StartLevel = 18215
    ONCE Box = 5*pipsize
    if not onmarket then
    IF Trend = 1 THEN //UP
    IF close <= (StartLevel – Box) THEN
    SELLSHORT 0.5 CONTRACT AT MARKET
    SET TARGET PRICE close – 5*PipSize
    SET STOP PRICE close + 5*PipSize
    ENDIF
    ELSIF Trend = -1 THEN //DOWN
    IF close >= (StartLevel + Box) THEN
    BUY 0.5 CONTRACT AT MARKET
    SET TARGET PRICE close + 5*PipSize
    SET STOP PRICE close – 5*PipSize
    ENDIF
    ENDIF
    ENDIF
    // trailing start
    IF LongOnMarket THEN
    IF close <= (StartLevel – 5*PipSize) THEN
    StartLevel = StartLevel – 5*PipSize
    ENDIF
    ELSIF ShortOnMarket THEN
    IF close >= (StartLevel + 5*PipSize) THEN
    StartLevel = StartLevel + 5*PipSize
    ENDIF
    ENDIF
    // Stop e target
    SET STOP pLOSS 5
    SET TARGET pPROFIT 5

    #230421 quote
    robertogozzi
    Moderator
    Master

    Su quale strumento e timefreame l’hai provato?

Viewing 15 posts - 1 through 15 (of 20 total)
  • You must be logged in to reply to this topic.

dax 50 strategia


ProOrder: Trading Automatico & Backtesting

New Reply
Author
Summary

This topic contains 19 replies,
has 2 voices, and was last updated by Francesco Rossi
1 year, 11 months ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 03/18/2024
Status: Active
Attachments: No files
Logo Logo
Loading...