Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Order Flow VWAP No Session Breaks on Historical

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Order Flow VWAP No Session Breaks on Historical

    Hello,

    I have a strategy that uses Calculate.OnEachTick and Order Flow VWAP using VWAPResolution.Tick added inside the strategy. The strategy works well with the indicator when using Realtime data feed from IB, but the VWAP indicator breaks during historical processing (no session resets occur) since IB doesn't have historical tick data. Because the strategy uses VWAP for certain calculations, it is important that the VWAP bands reset at the beginning of each session and not where Historical transitions to Realtime. In the screen shots below, the one that has no historical tick data doesn't see the session breaks but the one with tick data resets correctly at the end of every session.

    I have tested that the Order Flow VWAP indicator correctly resets on the session breaks with Calculate.OnBarClose and Standard resolution for historical non-tick feeds, however this isn't the setting I want for the strategy.

    I'd like to know if there is a way to use Order Flow VWAP so it shows the session breaks properly when using historical non-tick data and then transition to using tick data when entering Realtime mode so the strategy can have the granularity it needs.

    I have also attached some bare-bones code I have been using for testing this issue.


    NT8 Version 8.0.24.1 - 64bit
    Screenshots show:
    Tick Replay = Disabled
    Trading Hours = US Equitues ETH
    Datafeed has no tick data (IB)


    Screenshot #1 has OFVwap resolution = Tick and Strategy set to Calculate.OnEachTick

    Screenshot #2 has OFVwap resolution = Standard and Strategy set to Calculate.OnBarClose


    Any insights you have would be great. Thanks!
    Attached Files

    #2
    Hello CCLQMT,

    Thanks for your post.

    There is not a way to set the resolution to tick/standard specifically for historical data, and if we are using a resolution of tick, we would need the historical tick data for the indicator to function properly.

    Something you could consider, would be to create a shell indicator that adds plots to display each VWAP line, and then within that indicator, add a standard resolution and a tick based resolution VWAP. You could then plot the standard resolution in the shell indicator with if(State == State.Historical) and the tick resolution with realtime.

    Please let us know if there is anything else we can do to help.
    JimNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Fer123, Yesterday, 04:57 PM
    1 response
    7 views
    0 likes
    Last Post NinjaTrader_Jim  
    Started by Cormick, Today, 06:26 AM
    0 responses
    4 views
    0 likes
    Last Post Cormick
    by Cormick
     
    Started by torch2k, Today, 06:24 AM
    0 responses
    3 views
    0 likes
    Last Post torch2k
    by torch2k
     
    Started by Devside_Victor, Today, 04:57 AM
    0 responses
    1 view
    0 likes
    Last Post Devside_Victor  
    Started by johnMoss, Yesterday, 10:40 PM
    0 responses
    9 views
    0 likes
    Last Post johnMoss  
    Working...
    X