# Need help from the community HigherHighLower Lows Indicator

**URL:** <https://community.tradovate.com/t/need-help-from-the-community-higherhighlower-lows-indicator/7374>\
**Category:** Tradovate Feature Requests\
**Created:** [June 8, 2023, 6:52pm UTC](https://community.tradovate.com/t/need-help-from-the-community-higherhighlower-lows-indicator/7374 "2023-06-08T18:52:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fred\_Naef](https://avatars.discourse-cdn.com/v4/letter/f/dc4da7/32.png) [@Fred\_Naef](https://community.tradovate.com/u/Fred_Naef)\
**Post date:** [June 8, 2023, 6:52pm UTC](https://community.tradovate.com/t/need-help-from-the-community-higherhighlower-lows-indicator/7374/1 "2023-06-08T18:52:07Z")

</div>

Hi , 🙂 See below, need help  
ThinkorSwim Indicator, help to code to Tradovate Java script. Great practical indicator  
as follows:  
I would love to see this HHLL indicator from ThinkorSwim on Tradovate:

It is great for Bull and Bear Flags and is just fantastic. It would be a great addition from one of your inhouse developers like Alexander.

Question:

Can someone put this into Tradovate Java Script?

see below the TOS usethink script

declare lower;

input length = 20;

input over\_bought = 60;

input signal\_line = 50;

input over\_sold = 10;

input averageType = AverageType.EXPONENTIAL;

Assert(length \> 1, "‘length’ must be greater than one: " + length);

def HH = if high \> high[1] then (high - Lowest(high, length)) / (Highest(high, length) - Lowest(high, length)) else 0;

def LL = if low \< low[1] then (Highest(low, length) - low) / (Highest(low, length) - Lowest(low, length)) else 0;

plot HHS = 100 \* MovingAverage(averageType, HH, length);

plot LLS = 100 \* MovingAverage(averageType, LL, length);

plot OverBought = over\_bought;

plot SignalLine = signal\_line;

plot OverSold = over\_sold;

HHS.SetDefaultColor(GetColor(6));

LLS.SetDefaultColor(GetColor(5));

OverBought.SetDefaultColor(GetColor(7));

SignalLine.SetDefaultColor(GetColor(7));

OverSold.SetDefaultColor(GetColor(7));

AddLabel (yes, HHS, Color.WHITE);

AddLabel(yes, LLS, Color.RED);

End

Fred Naef

Sincerely

6/8/2023 6:25 AM
