Hi @BenTen, i would like to create a simple scan for stocks that have pullback to 30Day Moving Average and it is also oversold using CCI (-100). This is something i tried but was unable to get scan results that satisfy both conditions. It seems to be able to fulfill the Moving Average condition but not the CCI.... Is there something wrong with the code? Thank you
declare lower;
input bars = 30;
def ma = SimpleMovingAvg(close, bars);
def s = ma * 0.01;
def scan = AbsValue(close - ma) <= s;
################################################
def CCI = -100;
################################################
plot Signal = scan and CCI -100 ;
declare lower;
input bars = 30;
def ma = SimpleMovingAvg(close, bars);
def s = ma * 0.01;
def scan = AbsValue(close - ma) <= s;
################################################
def CCI = -100;
################################################
plot Signal = scan and CCI -100 ;