AIUTO LINGUAGGIO ProOrder

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #33193 quote
    Riccardo Benedetti
    Participant
    Junior

    Salve a tutti,

    ho scaricato un indicatore dalla libreria e sto provando a creare una strategia.

    Ho letto il manuale scaricato da prorealtime ho consultato la guida di prorealcode ma non riesco.

    richiamando l’indicatore con la funzione CALL i parametri vengono importati?

    ho provato anche a copiare il codice e cercare di programmare ma faccio degli errori.

    se qualcuno mi può aiutare glie ne sarei veramente grato.

    #33199 quote
    Nicolas
    Keymaster
    Master

    Dovresti fornire almeno il nome dell’indicatore e il codice che hai provato! Dovrebbe essere un buon inizio per aiutarti! 🙂

    #33207 quote
    Riccardo Benedetti
    Participant
    Junior

    Hai ragione Nicolas ma sono nuovo e non pratico social in genere. non vorrei violare privacy ed essere invadente.

    Il nome dell’indicatore è PRChalftrend.

    io ho provato con

    myindic= call “PRC_Halftrend”[2]

    IF NOT LongOnMarket AND myindic=1 THEN
    BUY 1 CONTRACTS AT MARKET
    ENDIF

    ho scritto myindic = 1 perchè nel codice 1 stava per colore up

    grazie mille.

    #33208 quote
    Riccardo Benedetti
    Participant
    Junior

    ho dimenticato di dire che devo entarte long e short quando l’indicatore cambia colore!

    scusami

    #33238 quote
    Nicolas
    Keymaster
    Master

    Capisco la tua query. Il codice qui sotto dovrebbe funzionare come un sistema completo di trading automatizzato per l’indicatore di halftrend. Dovresti anche aggiungere te stesso codice takeprofit e stoploss!

    //PRC_HalfTrend | indicator
    //10.03.2017
    //Nicolas @ www.prorealcode.com
    //Sharing ProRealTime knowledge
    
    defparam cumulateorders=false
    
    Amplitude = 2
    
    lowpricei = Lowest[Amplitude](low)
    highpricei = Highest[Amplitude](high)
    lowma = average[Amplitude](low)
    highma = average[Amplitude](high)
    
    if barindex>Amplitude then
    
    if(nexttrend=1) then
    
    maxlowprice=Max(lowpricei,maxlowprice)
    
    if(highma<maxlowprice and Close<Low[1]) then
    trend=1.0
    nexttrend=0
    minhighprice=highpricei
    endif
    
    endif
    
    if(nexttrend=0) then
    
    minhighprice=Min(highpricei,minhighprice)
    
    if(lowma>minhighprice and Close>High[1]) then
    trend=0.0
    nexttrend=1
    maxlowprice=lowpricei
    endif
    
    endif
    
    if(trend=0.0) then
    
    if(trend[1]<>0.0) then
    up=down[1]
    else
    up=Max(maxlowprice,up[1])
    endif
    down=0.0
    
    else
    
    if(trend[1]<>1.0) then
    down=up[1]
    else
    down=Min(minhighprice,down[1])
    endif
    up=0.0
    endif
    
    endif
    
    if up>0 then
    color = 1
    else
    color = -1
    endif
    
    if not longonmarket and color=1 and color[1]=-1 then 
    buy 1 contract at market 
    endif
    
    if not shortonmarket and color=-1 and color[1]=1 then 
    sellshort 1 contract at market 
    endif 
    ALE thanked this post
    #33244 quote
    Riccardo Benedetti
    Participant
    Junior

    Ti ringrazio tanto Nicolas.

    Mi sei stato veramente d’aiuto.

    #33687 quote
    Riccardo Benedetti
    Participant
    Junior

    ciao Nicolas,

    ho provato ad avviare il sistema ma non mi esegue gli ordini, mentre nel backtest è tutto ok.

    sai quale potrebbe essere il problema?

    grazie ancora

    #33705 quote
    Nicolas
    Keymaster
    Master

    mi dispiace non lo so! Dimensione minima del contratto può essere? Su quale strumento? I messaggi negli ordini di carta? (CTRL+O)

    #33706 quote
    Riccardo Benedetti
    Participant
    Junior

    EUR USD e GBP USD. dimensione di contratto 1 mini. nessun messaggio negli ordini.

    stop nei limiti richiesti.

    #33774 quote
    Riccardo Benedetti
    Participant
    Junior

    problema risolto grazie.

    ho riavviato la piattaforma e il sistema è partito.

    non so cosa fosse successo. comunque grazie tanto!

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

AIUTO LINGUAGGIO ProOrder


ProOrder: Trading Automatico & Backtesting

New Reply
Summary

This topic contains 9 replies,
has 2 voices, and was last updated by Riccardo Benedetti
8 years, 9 months ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 04/24/2017
Status: Active
Attachments: No files
Logo Logo
Loading...