Here is my favorite starting place, works with 1 year charts. Solid for IV Rank
# --------------START BELOW THIS LINE---------------
# IV Rank tells traders where the Implied Volitility lies in relation
# to its yearly high and low Implied Volitility
#
#-------------------TO INSTALL--------------------------
# Start ThinkorSwim
# Click the Chart tab
# Click the Studies button
# Select Edit Studies
# Click New button
# Erase Everything in the box (plot Data = close
# Paste the text in this page into the box
# Insert the name: IV Rank Levels
# Click OK
# Click OK
# ------------------HAVE A NICE DAY--------------------
declare lower;
declare hide_on_intraday;
#IVPercentile
def vol = imp_volatility();
input ImpVolatility= yes;
input IVPercentile = yes;
input DailyStandardDeviation = yes;
input WeeklyStandardDeviation = yes;
input MonthlyStandardDeviation = yes;
input TimePeriod = 252;
def data = if !isNaN(vol) then vol else vol[-1];
def hi = highest(data, TimePeriod);
def lo = lowest(data, TimePeriod);
plot Percentile = (data - lo) / (hi - lo) * 100;
def lowend = Percentile < 20;
def highend = Percentile > 50;
#Labels
addlabel(IVPercentile , concat("IV Rank: ",aspercent(Percentile /100)), if lowend then color.red else if highend then color.green else color.yellow);
addlabel(ImpVolatility, concat("ImpVolatility: ",aspercent(vol)), if lowend then color.red else if highend then color.green else color.yellow);
def Hold1 = (vol / Sqrt(252)) * close;
AddLabel(DailyStandardDeviation, Concat("Daily SD $", Astext( Hold1, NumberFormat.TWO_DECIMAL_PLACES)), if lowend then color.red else if highend then color.green else color.yellow); ;
def Hold2 = (vol / Sqrt(52)) * close;
AddLabel(WeeklyStandardDeviation, Concat("Weekly SD $", Astext( Hold2, NumberFormat.TWO_DECIMAL_PLACES)), if lowend then color.red else if highend then color.green else color.yellow); ;
def Hold3 = (vol / Sqrt(12)) * close;
AddLabel(MonthlyStandardDeviation , Concat("Monthly SD $", Astext( Hold3, NumberFormat.TWO_DECIMAL_PLACES)), if lowend then color.red else if highend then color.green else color.yellow); ;
plot LowVol = 20;
plot HighVol = 50;
LowVol.SetDefaultColor(GetColor(5));
HighVol.SetDefaultColor(GetColor(6));