![]() |
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
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Member
Join Date: Jul 2011
Posts: 38
Thanks: 15
Thanked 1 time in 1 post
|
I was wondering if anyone has a clever way to calculate the highest high or lowest low over a number of bars.
The Max and Min functions only accept two values, and I can create a series of statements checking back one bar at a time, but that seems ponderous and like there must be a more clever way. Any thoughts? |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Hi Grasul,
The built in indicators MAX() and MIN() offer this. You may be looking at Math.Min and Math.Max which only accept two values.
Ryan M
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Member
Join Date: Jul 2011
Posts: 38
Thanks: 15
Thanked 1 time in 1 post
|
Thanks for your help.
|
|
|
|
|
|
#4 |
|
Senior Member
Join Date: Aug 2010
Location: Washington, D.C.
Posts: 1,189
Thanks: 180
Thanked 302 times in 260 posts
|
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Highest High Lowest Low N bars back | Ccowl1 | General Programming | 6 | 11-05-2010 01:47 PM |
| Highest High/Lowest low of last 'n' bars | hari_krishna | Indicator Development | 1 | 02-15-2010 07:00 AM |
| Indicator displaying highest/lowest close instead of high/low | atxtrader | Indicator Development | 3 | 12-14-2009 10:28 AM |
| Charting Highest High And Lowest Low Of Prior Day | pedroprada@bellsouth.net | Charting | 3 | 12-29-2008 10:17 AM |
| highest high / lowest low of first hour of trading | velocity | General Programming | 7 | 06-16-2008 09:07 AM |