Scan for a drop of a certain amount in price down from 5 bars ago
I'm trying to get this scan to alert when price drops, any suggestion on why this doesn't work?
input length = 1;
input price = OHLC4;
input averageType = AverageType.SIMPLE;
def avg = MovingAverage(averageType,price,length);
def height = avg - avg[5];
plot scan = height < -.55 ;
I'm trying to get this scan to alert when price drops, any suggestion on why this doesn't work?
input length = 1;
input price = OHLC4;
input averageType = AverageType.SIMPLE;
def avg = MovingAverage(averageType,price,length);
def height = avg - avg[5];
plot scan = height < -.55 ;
Last edited by a moderator: