only one trade per day on 3 strategies

Viewing 15 posts - 31 through 45 (of 60 total)
  • Author
    Posts
  • #17602 quote
    dreif123
    Participant
    Average

    cosmic, you also made some suggestions on some other strategies which done work for only one execution which dont work.
    comments are generell helpfully when i get answers on what i am asking….and not if someone ask me on currcencystuff, when i was asking on dax mini in the 1minute chart.
    so if you are able to help on my bollingerrequest for only one execution, than pleaese go for it…..

    #17604 quote
    Nicolas
    Keymaster
    Master

    Hey guys, stay calm! and keep trading 🙂

    Maybe the instrument you are trying to test never met the 000000 time condition, usually I used intradaybarindex to reset this kind of variable: (Roberto example with this modification)

    // onlu ONE trade per Day
    //
    Defparam cumulateorders = false
    defparam flatbefore     = 080000
    defparam flatafter      = 173000
    ONCE OneTrade           = 0
    IF intradaybarindex=0 THEN
    OneTrade = 0
    ENDIF
    indicator1 = close
    indicator2 = Bollingerdown[20](close)
    c1 = (indicator1 < indicator2)
    c2 = (OneTrade = 0)
    if c1 AND c2 then
    buy 20 contract at market
    OneTrade = 1
    endif
    set stop ploss 0
    set target pprofit 1

    Please test and comment, thank you.

    #17610 quote
    dreif123
    Participant
    Average

    nicolas thx for the
    i have put in as you said…but no single trade is shown on the backtesting,

    #17611 quote
    Nicolas
    Keymaster
    Master

    As you can see in this screenshot example, this code works well for me on DAX30 1minute, PRT-CFD account.

    What is the instrument tested and the timeframe please? What is your brokerage solution?

    one-trade-per-day-prorealtime-code.png one-trade-per-day-prorealtime-code.png
    #17629 quote
    Cosmic1
    Participant
    Senior

    This works for me too as does my suggestion to you, Dreif.

    Do you see the logic to copy in my suggestion?

    DEFPARAM CumulateOrders = False //
    defparam flatbefore=080000
    defparam flatafter=173000
    Once LastTradeDate = 0
    
    // Bedingungen zum Einstieg in Long-Positionen
    indicator1 = RSI[14](close)
    c1 = (indicator1 < 20)
    
    IF c1 And LastTradeDate<>OpenDate THEN
    BUY 6 CONTRACT AT MARKET
    LastTradeDate = OpenDate
    ENDIF
    
    // Stops und Targets
    SET STOP pLOSS 20
    set target pprofit 5
    Nicolas thanked this post
    Capture-1.png Capture-1.png
    #17635 quote
    dreif123
    Participant
    Average

    cosmic,
    I copy that to the bollup strategie …. result : again not working …

    DEFPARAM CumulateOrders = False //
    defparam flatbefore=080000
    defparam flatafter=173000
    Once LastTradeDate = 0
    
    // Bedingungen zum Einstieg in Long-Positionen
    indicator1 = close
    indicator2 = BollingerUp[20](close)
    c1 = (indicator1 > indicator2)
    IF c1 And LastTradeDate<>OpenDate THEN
    sellshort 10 CONTRACT AT MARKET
    LastTradeDate = OpenDate
    ENDIF
    
    // Stops und Targets
    SET STOP pLOSS 0
    set target pprofit 1
    #17663 quote
    dreif123
    Participant
    Average

    Nicolas , your suggestion for the rsi doesn’t work for that I was asking ….for the bollstuff ….

    #17665 quote
    Nicolas
    Keymaster
    Master

    Here we go again .. here is the code for bollinger up stuff:

    DEFPARAM CumulateOrders = False //
    defparam flatbefore=080000
    defparam flatafter=173000
    ONCE OneTrade           = 0
    IF intradaybarindex=0 THEN
    OneTrade = 0
    ENDIF
    
    // Bedingungen zum Einstieg in Long-Positionen
    indicator1 = close
    indicator2 = BollingerUp[20](close)
    c1 = (indicator1 > indicator2)
    IF c1 And OneTrade=0 THEN
    sellshort 1 CONTRACT AT MARKET
    OneTrade=1
    ENDIF
    
    // Stops und Targets
    set target pprofit 1


    This code DO WORK (and the last one too..)

    You still haven’t answered to my last question:

    What is the instrument tested and the timeframe please? What is your brokerage solution?

    Please give details about what you believe it is not working at all? At least screenshot ..! Everyone here is kindly trying to help you, so please have this in mind when you post message! Thanks in advance 🙂

    thanked this post
    #17746 quote
    dreif123
    Participant
    Average

    sorry nicolas…. ihave cpy past your bollstoff code …result : no trade on proreal backtesting…..

    #17748 quote
    dreif123
    Participant
    Average

    lets finish that , i found anothter way to create ….with the function quit.
    probably someone can help on that, …on daxmini, 1minute,
    its an one day strategie,…what do i have to add on the code, if the system continious!!!!!! should by 5 contracts at market…so if dema(13)
    crosses over dema(38) the system should always 5 contract at market when the crossing takes place

    defparam flatbefore=080000
    defparam flatafter=173000
    
    // Bedingungen zum Einstieg in long-Positionen
    indicator1 = DEMA[13](close)
    indicator2 = DEMA[38](close)
    
    c1 = (indicator1 CROSSES over indicator2)
    
    IF c1 THEN
    buy 5 CONTRACT AT MARKET
    ENDIF
    #17759 quote
    Nicolas
    Keymaster
    Master

    Still not get answers to my last question…

    #17771 quote
    dreif123
    Participant
    Average

    here is the missing answers
    dax mini 1 euro
    1 minute chart
    no brockerage

    #17772 quote
    dreif123
    Participant
    Average

    timeframe 02.10.2016 to 02.12.2016
    on 080000 to 173000

    #17798 quote
    Nicolas
    Keymaster
    Master

    Well, there must be something wrong somewhere on your side, it works well here.

    strategy-tester-prorealtime-dax.png strategy-tester-prorealtime-dax.png
    #17808 quote
    dreif123
    Participant
    Average

    hi Nicolas, thx so far
    any idea to help on my question on 3dez at 9:54?

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

only one trade per day on 3 strategies


Platform Support: Charts, Data & Broker Setup

New Reply
Author
author-avatar
dreif123 @dreif123 Participant
Summary

This topic contains 59 replies,
has 6 voices, and was last updated by Andy11
9 years ago.

Topic Details
Forum: Platform Support: Charts, Data & Broker Setup
Language: English
Started: 11/04/2016
Status: Active
Attachments: No files
Logo Logo
Loading...