Entrare a mercato gli utlimi 10 minuti prima della chiusura

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #24470 quote
    MaxMax
    Participant
    Average

    Qui di seguito una domanda inviata a ProRealTime :

     

    Voglio creare il seguente trading system:

    – individuare per ogni giorno, entro un determinato orario, il massimo e il minimo. Quindi il max e min price deve essere ridefinito ogni giorno entro un determinato orario. Esempio su indice DJ che apre ora italiana alle 1530 e chiude alle 2230. L’idea è quella ad esempio di individuare max e min tra le 1530 e le 22 ed entrare a mercato gli ultimi 10 minuti (quindi dalle 22.01 e alle 2210) e se non raggiunto target impostato chiude la posizione alle 2210. Ovviamente gli orari devono essere parametrizzabili;

    – Time frame migliore è 1 minuto in modo da avere maggiore flessibilità di entrata nel definire gli orari.

     

     E un esempio di risposta :

    defparam flatbefore=220100
    defparam flatafter=221000
    
    starttime=153000
    endtime=220000
    
    timetotrade=220100
    if opentime=starttime or (opentime > starttime and opentime[1] < starttime) then
    mymax=high
    mymin=low
    elsif opentime> starttime and time <=endtime then
    mymax=max(high,mymax)
    mymin=min(low,mymin)
    endif
    
    if time = timetotrade then
    buy 1 share at market
    sell at mymin stop
    sell at mymax limit
    endif
    
    if longonmarket then
    sell at mymin stop
    sell at mymax limit
    endif
    #44231 quote
    RiccardoRiccardo
    Participant
    Senior

    Salve Max

    buona l’idea

     

    ma che ne dici di provare questo codice all’apertura USA ?

    #44774 quote
    Leonida1984Leonida1984
    Participant
    Average

    Max buon pomeriggio, una domanda: nel tuo codice tu non vai a vedere il massimo e il minimo di giornata, giusto?

    Mi risulta difficile capire la tua idea di trading. Te ne sarei grato se me la potessi spiegare.

    Grazie!

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

Entrare a mercato gli utlimi 10 minuti prima della chiusura


ProOrder: Trading Automatico & Backtesting

New Reply
Author
author-avatar
Max @max Participant
Summary

This topic contains 2 replies,
has 3 voices, and was last updated by Leonida1984Leonida1984
9 years, 1 month ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 02/09/2017
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...