How can I modify this TOS TD Ameritrade indicator to a 30 minute PriceOsc that functions (as it would on a 30 minute chart) instead on a 5 minute chart? Would I need to change it to a MTF format? If so, is there a formula for that? I would appreciate any suggestions. Thank you!
# PriceOsc
# TD Ameritrade IP Company, Inc. (c) 2007-2023
declare lower;
input colorNormLength = 14;
input fastLength = 9;
input price = close;
input slowLength = 18;
input averageType = AverageType.SIMPLE;
plot PriceOsc = MovingAverage(averageType, price, fastLength) - MovingAverage(averageType, price, slowLength);
plot ZeroLine = 0;
PriceOsc.DefineColor("Highest", Color.YELLOW);
PriceOsc.DefineColor("Lowest", Color.LIGHT_RED);
PriceOsc.AssignNormGradientColor(colorNormLength, PriceOsc.color("Lowest"), PriceOsc.color("Highest"));
ZeroLine.SetDefaultColor(GetColor(8));
# PriceOsc
# TD Ameritrade IP Company, Inc. (c) 2007-2023
declare lower;
input colorNormLength = 14;
input fastLength = 9;
input price = close;
input slowLength = 18;
input averageType = AverageType.SIMPLE;
plot PriceOsc = MovingAverage(averageType, price, fastLength) - MovingAverage(averageType, price, slowLength);
plot ZeroLine = 0;
PriceOsc.DefineColor("Highest", Color.YELLOW);
PriceOsc.DefineColor("Lowest", Color.LIGHT_RED);
PriceOsc.AssignNormGradientColor(colorNormLength, PriceOsc.color("Lowest"), PriceOsc.color("Highest"));
ZeroLine.SetDefaultColor(GetColor(8));