NinjaScript > Educational Resources > Reference Samples > Indicator >

Calculating the highest high or lowest low for a specified time range

Print this Topic Previous pageReturn to chapter overviewNext page

Determining a high or low value for given time range can be useful.

 

Key concepts in this example

Converting time to bars ago values
Getting the highest high and lowest low values

 

Important related documentation

GetBar()
MAX()
MIN()

 

Import instructions

1.Download the file contained in this Help Guide topic to your PC desktop
2.From the Control Center window, select the menu File > Utilities > Import NinjaScript
3.Select the downloaded file and click Import.

 

SampleGetHighLowByTimeRange_NT7.zip