different Pivot Points TimeFrame

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #57867 quote
    Inertia
    Participant
    Master

    Hi,

    I have two strategies but one based on crossing the Daily PP, the other one is based on crossing 4hrs PP.

    Looking at the code into both strategies, I do not see any differences…

    Q: How can the system recognise the different TF ??

    Thank you.

    // Pivots points TF 4 hrs
    indicator1 = (DHigh(1) + DLow(1) + DClose(1))/3
    c1 = (close CROSSES OVER indicator1)
    
    // Pivots points TF daily
    indicator1 = (DHigh(1) + DLow(1) + DClose(1))/3
    c1 = (close CROSSES OVER indicator1)
    
    // Q: How does Proorder recognise the different TF please ??
    
    IF c1 THEN
    BUY 1 CONTRACT AT MARKET
    ENDIF
    #57871 quote
    GraHal
    Participant
    Master

    Just a thought … is one Strat running on Live and the other Strat on Demo?

    #57872 quote
    Nicolas
    Keymaster
    Master

    Your 4 hours pivot points calculation at line 2 is incorrect, it is the Daily one (same as the one at line 6).

    Also, it is not a good idea to name 2 different variables with the same label like you did (indicator1 and c1). Code is read from top to bottom, so your first condition c1 will always be overridden by the one at line 7.

    #57873 quote
    Vonasi
    Moderator
    Master

    It doesn’t. The pivot points are just calculated off of yesterdays High, Low and Close which will be exactly the same whatever time frame you are in. The Pivot points will be at exactly the same levels.

    #58569 quote
    Inertia
    Participant
    Master

    I have added pictures to make it clearer 🙂 (so far thank you for your interest).

    Pictures shows the PP set up on 4 hours.

    The strategy below (c1: price crosses over  the PPr1 4hr)…but the code doesn’t show it, same as daily…

    PP-4-hours.png PP-4-hours.png PP-4-hours-code.png PP-4-hours-code.png
    #58572 quote
    Inertia
    Participant
    Master

    And daily details.

    I do not have glasses yet… perhaps I will consider bying a pair ;)) cause I do no see the difference…

    Thx

    PP-Daily.png PP-Daily.png PP-Daily-code.png PP-Daily-code.png
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.

different Pivot Points TimeFrame


ProOrder: Automated Strategies & Backtesting

New Reply
Author
author-avatar
Inertia @inertia Participant
Summary

This topic contains 5 replies,
has 4 voices, and was last updated by Inertia
8 years, 1 month ago.

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 01/09/2018
Status: Active
Attachments: 4 files
Logo Logo
Loading...