New Members: Be sure to confirm your email address by clicking on the link that was sent to your email inbox. You will not be able to post messages until you click that link.
Please help with Weekly and Monthly Inside Bar Scan
Hello everyone,
Can someone please help with how to create a weekly (triple inside bar, double inside bar, and single inside bar scan) and monthly (triple, double, and single inside bar scan) ?
I can't see time period on weekly time frame, what am I missing?
Thank you in advance.
Regards,
Rock
0
Comments
So, to keep it simple, I'm going to define an inside bar as a bar with a lower high and a higher low than the previous bar.
For daily, it would be
and [high < 1 day ago high]
and [low > 1 day ago low]
For weekly, you have to add modifiers to ALL the terms, so
and [weekly high < 1 week ago weekly high]
and [weekly low > 1 week ago weekly low]
For monthly, substitute "month" and "monthly" for "week" and "weekly"
For the consecutive inside bars, you need the same code, but with offsets adjusted:
// the current week's bar is an inside bar (same as above)
and [weekly high < 1 week ago weekly high]
and [weekly low > 1 week ago weekly low]
// last week's bar was also an inside bar (offsets adjusted by 1)
and [1 week ago weekly high < 2 weeks ago weekly high]
and [1 week ago weekly low > 2 weeks ago weekly low]
// and the bar two weeks ago was also an inside bar (offsets adjusted by 1 again)
and [2 weeks ago weekly high < 3 weeks ago weekly high]
and [2 weeks ago weekly low > 3 weeks ago weekly low]
I'm leaving out the possibility that two highs or two lows could be equal and some would consider that an inside bar. If you want to include those, change ">" to ">=" and "<" to "<=".
You should also have two different chart styles ready to go - say two years weekly and 5 years monthly - to view your results. Save the results to a list, then open the list, click on a symbol to got to the workbench, change the style to weekly or monthly, click "apply to all" down at the bottom, then change the view to see all charts.
Monthly bars are the same. The current monthly bar reflects the prices from the 1st trading day of the month through the month to date close. If you run a scan today for monthly bars and include the current month bar in your scan, that monthly bar is made up of combined data from May 1 to May 26. So not a full month.
To make sure that you are using the full bars for weekly and monthly scans you need to run them at a week end or month end date. You can select the date using the Calandar on the scan workbench where the 0 is. Click on that and select a week ending or month ending date.
So if you run a scan looking at the current bar on any day other than EOD Friday to before trading begins for the next week, the weekly high, for example, will be the partial week data used. If you run it on Wednesday, the current weekly bar will be reflect the combined data from Monday, Tuesday and whatever time you ran the scan on Wednesday.
and [weekly high < 1 week ago weekly high]
Thank you markd and Imkwin. Btw, these scans are amazing for swing traders like me.