NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Indicator Development

Indicator Development Support for the development of custom indicators using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 06-13-2008, 12:45 AM   #1
mgbloomfield
Senior Member
 
Join Date: Dec 2006
Location: Seattle, Washington, USA
Posts: 150
Thanks: 0
Thanked 0 times in 0 posts
Default Compute Highest High between 9:30 AM and 10:30 AM

How would you compute the highest high between 9:30 AM and 10:30 AM?
mgbloomfield is offline  
Reply With Quote
Old 06-13-2008, 01:18 AM   #2
NinjaTrader_Josh
NinjaTrader Product Manager
 
NinjaTrader_Josh's Avatar
 
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 107 times in 70 posts
Default

When it becomes 10:30 use the MAX() function along with a calculated number of bars that will bring you back to 9:30 and then save that value.
NinjaTrader_Josh is offline  
Reply With Quote
Old 06-13-2008, 06:14 AM   #3
Elliott Wave
Senior Member
 
Join Date: Mar 2008
Posts: 731
Thanks: 0
Thanked 1 time in 1 post
Default

You might also want to search for "Directional Day Filter", it may already do what you want.
Elliott Wave is offline  
Reply With Quote
Old 06-13-2008, 11:35 AM   #4
mgbloomfield
Senior Member
 
Join Date: Dec 2006
Location: Seattle, Washington, USA
Posts: 150
Thanks: 0
Thanked 0 times in 0 posts
Default

Quote:
Originally Posted by Elliott Wave View Post
You might also want to search for "Directional Day Filter", it may already do what you want.
Doing this search doesn't turn up anything on the forums. (Had to use "Directional Filter" because the search words must be 4+ length).

"Directional Day Filter" not listed in the Online Guide.
mgbloomfield is offline  
Reply With Quote
Old 06-13-2008, 11:42 AM   #5
Elliott Wave
Senior Member
 
Join Date: Mar 2008
Posts: 731
Thanks: 0
Thanked 1 time in 1 post
Default

Ah yes, the pesky 4 letter minimum, incredibly annoying considering how many three letter acronyms there are in the trading lexicon.
Attached Files
File Type: zip DDF Gumphrie.zip (3.5 KB, 31 views)
Elliott Wave is offline  
Reply With Quote
Old 03-20-2013, 04:26 PM   #6
bobc635
Junior Member
 
Join Date: Jul 2011
Location: Arizona
Posts: 9
Thanks: 5
Thanked 0 times in 0 posts
Default

Hi Josh, I am trying to use snippets of your code from the sample. How would I look back to yesterday at 13:30 or day before yesterday from your staement???
startDateTime = new DateTime(Time[0].Year, Time[0].Month, Time[0].Day, 13, 30, 0);
I have tried a few things but banging my head against the wall.... Thanks for your example though, it is helpful.

Thanks
BobC635
bobc635 is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Retrieving Highest High for today 1reason Indicator Development 1 01-12-2008 01:59 PM
Highest High in a LookBack Period daven Indicator Development 2 09-28-2007 12:39 PM
Highest high of a time frame pablo_lasuncion Strategy Development 5 09-04-2007 02:05 PM
High greater than Highest High of last 20 Bars SamIam Strategy Development 1 08-19-2007 04:58 PM
Chart's highest is different to dome highest MrBaffalo Charting 16 03-08-2007 04:21 AM


All times are GMT -6. The time now is 08:33 AM.