Registered User Joined: 9/13/2014 Posts: 11
|
Dear Bruce,
I would need your support, when it comes to a combination of EMA9 and VWAP in writing a pcf
It should be checked, that the last 4 - EMA9 bars are below VWAP
Additionally, that the last 4 bars of EMA9 below EMA20
thanks in advance
Rainer
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
The last 4 bars of EMA9 below EMA20 part can be created as a Condition Formula.
XAVGC9 < XAVGC20 AND XAVGC9.1 < XAVGC20.1 AND XAVGC9.2 < XAVGC20.2 AND XAVGC9.3 < XAVGC20.3
There isn't a way to create a similar formula for EMA9 being below the plain VWAP indicator. It would be possible if you meant the Moving VWAP, but I assume this is not what you are using since you did not mention a period for VWAP.
It is still possible to scan for what you want, but creating the conditions is a bit complicated. Start by clicking on the EMA9 and selecting Create Scan Condition, you will want to create a condition for the EMA9 being below VWAP.
Create Conditions from Your Chart (5:25)
We will need to create three more similar conditions for past values. To do this, we can add 1-period exponential moving averages to both EMA9 and VWAP. Note these moving averages are exactly the same as EMA9 and VWAP.
To create the 1-bar ago condition, change the offset of the 1-period exponential moving averages to 1. Then click on the offset moving average of EMA9 and select Create Scan Condition. You will want the offset moving average of EMA9 to be below the offset moving average of VWAP.
Repeat this process with the offset settings set to 2 and 3. You can add all of the conditions to the same EasyScan to scan for your requirements (including the formula given at the top of this post).
Building a Scan with Multiple Conditions (7:29)
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
Registered User Joined: 9/13/2014 Posts: 11
|
thanks Bruce,
ok, I meant moving EMA9 three days ago < VWAP three days ago, EMA9 2 days ago < VWAP 2 days ago, EMA9 one day ago < VWAP one day ago and EMA9 current < VWAP current.
Hope I explained it a better way.
thanks Rainer
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
VWAP shouldn't plot on a daily or longer chart. It should only plot on intraday charts.
The instructions given in my original post essentially use offsets of 0, 1, 2 and 3 to make conditions for 4 bars. Adding an offset of 4 would allow you to make a condition for the fifth bar and add it to the EasyScan as well.
If you mean now and at the same time of day as now 1, 2, 3 and 4 bars ago, you could use offsets based on the number of intraday bars in a day in the intraday time frame of interest. For example, in a 30 minute time frame the offsets would be 13, 26, 39 and 52.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|