Weekly Daily Time Frame Back Testing

Optuma Forums Optuma Scripting Weekly Daily Time Frame Back Testing

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #64995
    Lester
    • Topics: 23
    • Replies: 36
    • Posts: 59

    Hi Everyone,

    I am looking to model a trading system which uses a Weekly time frame to Enter and a Daily time frame to Exit.

    Presently my system looks for a setup of certain conditions and if the next day’s price exceeds the previous Close a Buy occurs.  The precursory part (i.e., the setup conditions) of the Buy script use appropriate Weekly Time Frame override.  I assume that even though the Weekly Bar is not yet finished the trade pre-triggers even if the Weekly Bar is partly formed.

    To force the Back Tester to only pre-trigger at the close of the Week I used the following as one of the pre-trigger conditions.

    CLOSE(OFFSET=1) == WEEK()

    With an OFFSET of One Daily Bar the Close price of Friday should equate to WEEK() (which should be the same price).

    However, I do not think my trick is working.

    Is there another way to trick the Back Tester into only looking for Weekly Buys at the Friday close?

    Cheer, Lester

    #64997
    Darren
    • Topics: 66
    • Replies: 633
    • Posts: 699

    Hi Lester,

    You could try using the DAYOFWEEK() function, so adding ‘and DAYOFWEEK()==6’ will only trigger on Fridays.

    #65001
    Lester
    • Topics: 23
    • Replies: 36
    • Posts: 59

    Hi Darren,
    Thank you very much.  I knew there must be a way Optuma could handle this.

    Cheer, Lester

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

Pin It on Pinterest