non mi entra correttamente…

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #205094 quote
    Mauro M
    Participant
    New

     

    mi entra solo a prezzo di chiusura del giorno precedente. vorrei che mi entrasse a metà range del giorno precedente. Grazie.

     

    DEFPARAM CUMULATEORDERS=TRUE
    c1=CLOSE >OPEN
    C2=HIGH-CLOSE<=15
    SMA= average[25](close)
    C3=close>SMA

    c51=HIGH-low<=250
    C5=(high-low)>100
    C6=(high-low)/2
    k= close – c6
    C10=barindex-tradeindex=1
    // Condizioni per entrare su posizioni long
    IF C1 AND C2 AND C3 AND C5 and c51 THEN
    buy 1shares at k STOP
    ENDIF
    If LongOnMarket AND c10 THEN
    SELL AT MARKET
    ENDIF
    set stop ploss 70
    set target pprofit 140

    #205117 quote
    robertogozzi
    Moderator
    Master

    Metà del range è:

    k = high - c6   //oppure k = low + c6

    se aggiungi:

    graphonprice k

    vedrai bene il livello di prezzo.

    #205120 quote
    Mauro M
    Participant
    New

    Roberto anche come hai scritto tu entra sempre al prezzo di chiusura del giorno precedente e non a metà del range precedente . Testato sul dax sul daily.

    #205137 quote
    robertogozzi
    Moderator
    Master

    Cambia l’ordine pendente in LIMIT, evidentemente il prezzo a cui deve entrare è migliore rispetto alla chiusura, se è così entra a mercato.

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

non mi entra correttamente…


ProOrder: Trading Automatico & Backtesting

New Reply
Author
author-avatar
Mauro M @mauro-m Participant
Summary

This topic contains 3 replies,
has 2 voices, and was last updated by robertogozzi
3 years, 2 months ago.

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