How to setup scanner in PI for gap up strategy?

Hello

I want to know which stock gap up above last days high, so how can i setup a scanner in PI for this strategy plz let me know.

DEEPAK

As the scanner works only in live market on intraday and scanner starts from market opens so it is not possible to scan the gap ups

2 Likes

You can use below …give me response if it works for you,

Buy Signals

#A 2% gap up in price over the previous day on high volume
LOW > REF(HIGH,1) * 1.02 AND
VOLUME > SMA(VOLUME, 5) * 2

Sell Signals

#A 2% gap down in price over the previous day on high volume
HIGH < REF(LOW,1) * 0.98 AND
VOLUME > SMA(VOLUME, 5) * 2

Exit Long
Use a profit objective roughly ½ the size of the gap with a stop-loss.

Exit Short
Use a profit objective roughly ½ the size of the gap with a stop-loss.

no it will not working I used this script for back testing it shows error if you got succeed please kindly share the same scripts