Hi,
I am trying to build a script to use as a scan. Unfortunately, I am stuck.
I want to find stocks that:
- made a 252 day closing high in the last 10 days
- has closed below that new high by more than 25% but less than 38.2%.
Here is what I have. I know that my Variable 1 does return stocks that closed at a 252 day high in the last 10 days. I cannot figure out how to find stocks that have now closed 25% to 38.2% below that high returned in Variable 1.
thank you,
Louis.
//Calculate new 252 day closing high in the last 10 bars. V1 = CLOSE() >= HIGHESTHIGH(Close(), BARS=252, EQUAL=True, INCBAR=True) and TIMESINCESIGNAL(V1) <= 10; //Define 25% below V1 and 38.2% below V1. V2 = (V1 * -0.25); V3 = -(V1 * -0.382); //Show when conditions are true. Close() <= V2 and >= V3;