NexusFi: Find Your Edge


Home Menu

 





BT OPENING RANGE INDICATOR - without vertical lines at session changes


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one Fat Tails with 54 posts (161 thanks)
    2. looks_two rcabri with 9 posts (7 thanks)
    3. looks_3 meyer99 with 7 posts (0 thanks)
    4. looks_4 Big Mike with 6 posts (5 thanks)
      Best Posters
    1. looks_one Gabriyele with 4 thanks per post
    2. looks_two Fat Tails with 3 thanks per post
    3. looks_3 rcabri with 0.8 thanks per post
    4. looks_4 Big Mike with 0.8 thanks per post
    1. trending_up 47,196 views
    2. thumb_up 184 thanks given
    3. group 21 followers
    1. forum 109 posts
    2. attach_file 51 attachments




 
Search this Thread

BT OPENING RANGE INDICATOR - without vertical lines at session changes

  #41 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102

With NinjaTrader release NT 7.0.1000.5 one bug was fixed, they other one was not fixed. For more details see here:



I have checked again the code of the opening range indicator. It uses the flawed method GetNextBeginEnd() which which may return false values under specific conditions.

The bug only affects charts built from ticks (tick, volume, range, BetterRenko) with small periods, as used by scalpers. The problem is triggered by a first bar of session, which closes prior to 0:00:00:500 after the session begin.

Example: You trade ES and use a session template such that the session begin is the open at 8:30:00 CT. If the first bar of the session closes prior to 8:30:00:500, the bar will be attributed a time stamp of 8:30:00 by NinjaTrader. GetNextBeginEnd() may return the start time of the prior session instead of the current session.

I will leave a note here once the problem is fixed. The indicator can be used safely on minute bars and on all charts that do not fire bars within fractions of seconds.

Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
Exit Strategy
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
REcommedations for programming help
Sierra Chart
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
MC PL editor upgrade
MultiCharts
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Spoo-nalysis ES e-mini futures S&P 500
29 thanks
Just another trading journal: PA, Wyckoff & Trends
25 thanks
Tao te Trade: way of the WLD
24 thanks
Bigger Wins or Fewer Losses?
21 thanks
GFIs1 1 DAX trade per day journal
16 thanks
  #42 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102

I have to correct my previous post. GetNextBeginEnd() has a new overload, which I was not aware of, and which I could use for the indicator. The opening range indicator should now also work correctly on micro charts built from ticks.

I have also added some comfort to the indicator, the opening range can now be colored. Please test the version below, if you do not find any bugs, I will put it into the download sections.

The indicator requires NT 7.0.1000.5 or later, as the signature of GetNextBeginEnd() will not be recognized by earlier versions.

Attached Thumbnails
Click image for larger version

Name:	YM 06-11 (5 Min)  16_05_2011.jpg
Views:	344
Size:	87.7 KB
ID:	38713  
Attached Files
Elite Membership required to download: OpeningRangeV32.zip
Reply With Quote
  #43 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


Have updated the OpeningRange indicator in the Download section of the forum.


Reply With Quote
  #44 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102

Have updated the indicator again, as V32 sometimes refused to plot. The problem was related to the use of GetNextBeginEnd() in the custom Plot() of the indicator and should be fixed now.

The new version of the indicator can be downloaded here:




It will only work with NT 7.0.1000.5 or later.


Attached Thumbnails
Click image for larger version

Name:	ES 06-11 (15 Min)  24_05_2011.jpg
Views:	310
Size:	101.1 KB
ID:	39165  
Reply With Quote
  #45 (permalink)
 
Silvester17's Avatar
 Silvester17 
Columbus, OH
Market Wizard
 
Experience: None
Platform: NT 8, TOS
Trading: ES
Posts: 3,603 since Aug 2009
Thanks Given: 5,139
Thanks Received: 11,527

@ Fat Tails,

noticed something with the opening range indicator.

this time when you scroll all the way to the right I get the following error message.

was using TF on a 5 min chart, single data series, version V33

Attached Thumbnails
Click image for larger version

Name:	2011-06-09_1844.png
Views:	262
Size:	13.4 KB
ID:	40636  
Reply With Quote
Thanked by:
  #46 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


Silvester17 View Post
@ Fat Tails,

noticed something with the opening range indicator.

this time when you scroll all the way to the right I get the following error message.

was using TF on a 5 min chart, single data series, version V33

Thanks for reporting, I can see it here as well.

I checked all V33 indicators again, the OpeningRangeV33 is the only one that shows this behavior. It only occurs when horizontally scrolling the chart to the beginning.

It is possibly linked to the custom plot of the indicator, so it won't do any harm. Will explore this today and come back.

Reply With Quote
Thanked by:
  #47 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102

Had a look at the indicator. It was problem with the training period. When the indicator is put on a chart, it first does not know, how many sessions per day were selected by the user for the template. So it has to collect this information, before it can properly work.

During the training period a different logic is necessary to produce the presession range. For this reason the OpeningRangeV33 indicator produced an exception in the plot override section of the indicator, when you scrolled back to the beginning of the chart.

Some users who do not have historical tick data, but use real-time tick data, which they store over a few days may have problems with it.

To address the problem I have modified the indicator, as per version V34X1 attached below. I would appreciate, if anyone has the time to test it against the old version. You need to put on the pre-session range to check for the difference.

Thank you.

The indicator works with NT 7.0.1000.5 or later.

Attached Files
Elite Membership required to download: OpeningRangeV34X1.zip
Reply With Quote
  #48 (permalink)
 
Silvester17's Avatar
 Silvester17 
Columbus, OH
Market Wizard
 
Experience: None
Platform: NT 8, TOS
Trading: ES
Posts: 3,603 since Aug 2009
Thanks Given: 5,139
Thanks Received: 11,527


Fat Tails View Post
Had a look at the indicator. It was problem with the training period. When the indicator is put on a chart, it first does not know, how many sessions per day were selected by the user for the template. So it has to collect this information, before it can properly work.

During the training period a different logic is necessary to produce the presession range. For this reason the OpeningRangeV33 indicator produced an exception in the plot override section of the indicator, when you scrolled back to the beginning of the chart.

Some users who do not have historical tick data, but use real-time tick data, which they store over a few days may have problems with it.

To address the problem I have modified the indicator, as per version V34X1 attached below. I would appreciate, if anyone has the time to test it against the old version. You need to put on the pre-session range to check for the difference.

Thank you.

The indicator works with NT 7.0.1000.5 or later.

thanks fat tails.

I'm testing the 2 version against each other. so far no difference. except no error message with new version of course. will report back if I find anything else.

much appreciated.

Reply With Quote
Thanked by:
  #49 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


Silvester17 View Post
thanks fat tails.

I'm testing the 2 version against each other. so far no difference. except no error message with new version of course. will report back if I find anything else.

much appreciated.

The new version should plot differently for the training period of the indicator, which are the first 24 hours of your chart. You will only notice, if you horizontally scroll back to the beginning. Otherwise there should not be any differences.

Reply With Quote
  #50 (permalink)
 
Fat Tails's Avatar
 Fat Tails 
Berlin, Europe
Market Wizard
 
Experience: Advanced
Platform: NinjaTrader, MultiCharts
Broker: Interactive Brokers
Trading: Keyboard
Posts: 9,888 since Mar 2010
Thanks Given: 4,242
Thanks Received: 27,102


Thanks again to @Silvester17 for having identified the bug.

I have uploaded the new version V34 of the Opening Range Indicator to the download section.


Reply With Quote




Last Updated on January 22, 2019


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts