input OpenTime = 0930; input DurationHours = 1; def durationSec = DurationHours * 60 * 60; def secondsPassed = SecondsFromTime(OpenTime); def Markethours = if secondsPassed > 10 and secondsPassed < durationSec then 1 else 0; input length = 12; input over_Bought = 65; input over_Sold = 35; input price = close; input averageType = AverageType.WILDERS; input showBreakoutSignals = no; def NetChgAvg = MovingAverage(averageType, price - price[1], length); def TotChgAvg = MovingAverage(averageType, AbsValue(price - price[1]), length); def ChgRatio = if TotChgAvg != 0 then NetChgAvg / TotChgAvg else 0; plot RSI = 50 * (ChgRatio + 1); plot OverSold = over_Sold; plot OverBought = over_Bought; plot UpSignal = if RSI crosses above OverSold then OverSold else Double.NaN; plot DownSignal = if RSI crosses below OverBought then OverBought else Double.NaN; UpSignal.SetHiding(!showBreakoutSignals); DownSignal.SetHiding(!showBreakoutSignals); RSI.DefineColor("OverBought", GetColor(5))...