I want to scan and alert when the following conditions occur. The timeframe does not matter 15 min, 30 min, etc:
First candle opens above VWAP and closes below VWAP
Second candle opens below VWAP and closes above VWAP
Please see attached screenshot. I have not been able to figure out how to reference the 1st, 2nd, and 3rd candles of the day. Thanks in advance!
Marked as spam
Pete, Is there a way I can test what symbols would have shown up today 6/24/19 with the below code with two additional criteria now that the trading day is over? I would be scanning in All Nasdaq Stocks. Last minimum $12 Vol minumum 300,000
Not really. This task is complicated by the fact this code runs with extended hours data included. At this time of the day the post-market session is over. However many stocks have very limited trade volume in the extended hours. Which means you can't determine the number of candles to look back. It's going to vary depending on how many of those extended hours candles have trade data.
Pete, I have tried the code below the last two days adding a volume and price criteria to my scan with No results being returned. I have setup alerts from my scans to be emailed to me and I find it odd that nothing is being alerted. Based on your screenshot below it seems like scan should work. Would you please check my scan and tell me what I am missing? I have tried different time frame like 10 mins with the Ext box checked and unchecked with no luck. http://tos.mx/HsreyD
I opened the shared scan you posted in the comment above. The checkbox for extended hours was unchecked and the time frame was set to 5 min. This pattern is exceptionally rare. I believe that the lower your time frame is the more rare this signal becomes. I suggest you start with a 15 min and 30 min time frames until you start getting results.
As a test, I ran the following code on a 15 min time frame with extended hours checked. I came up with 11 results using your filters. This code looks back 39 bars to see if any valid signals occurred. It just so happens that for a 15 min time frame stocks with high after-market volume will have 40 of those 15 min candles, but only after 8 pm Eastern.
I only changed the last line in the code:
plot scan = Highest(conditionTwo, 39) > 0;
Please log in to post questions.