Add -50 Value to Williams%R indicator?

P

poparhon

New member
Need help in plotting the -50 into the code, a dashed black line ,appreciate any help Thanks
Code:
# TD Ameritrade IP Company, Inc. (c) 2007-2019
#

declare lower;

input length = 10;
input overBought = -20;
input overSold = -80;

def hh = Highest(high, length);
def ll = Lowest(low, length);
def result = if hh == ll then -100 else (hh - close) / (hh - ll) * (-100);

plot WR = if result > 0 then 0 else result;
WR.SetDefaultColor(GetColor(1));

plot Over_Sold = overSold;
Over_Sold.SetDefaultColor(GetColor(8));

plot Over_Bought = overBought;
Over_Bought.SetDefaultColor(GetColor(8));
 
BenTen

BenTen

Administrative
Staff
VIP
Add this to the end of the script:
Code:
plot negative_fifty = -50;
 
P

poparhon

New member
@BenTen appreciate the help on this, beats plotting this manually
 

Similar threads

Top