Scan Prior day close within current 5 minutes bar


Category:
0
0

Hello,

Is there way to write a scan where prior day closing price is within Todays’ current 5 minutes bars range?

Thanks in advance!

Marked as spam
Posted by (Questions: 1, Answers: 1)
Asked on September 29, 2021 9:06 am
92 views
0
Private answer

This solution works only if you exclude extended trading hours from the time frame settings of the Study Filter:

def newDay = GetDay() <> GetDay()[1];
rec priorDayClose = if newDay then close[1] else priorDayClose[1];
plot scan = high > priorDayClose and low < priorDayClose;

Marked as spam
Posted by (Questions: 37, Answers: 4118)
Answered on September 29, 2021 12:49 pm
0
Thank you very much! It's exactly what I wanted.
( at September 30, 2021 9:17 am)