Registered User Joined: 12/10/2004 Posts: 14
|
Need help writing a scan to find (C-XAVGC20) crossing signal line (XAVGC9).
THANK YOU!! jonedyer
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
I'm going to assume "signal line (XAVGC9)" means a 9-Period Exponential Moving Average of (C-XAVGC20) and not an EMA9 of Price since otherwise the lines should rarely even be near each other for most symbols. If so, a formula for C - XAVGC20 crossing up through its own 9-Period EMA could be written as:
11 * C + 8 * XAVGC20 > 19 * XAVGC9 AND 11 * C1 + 8 * XAVGC20.1 <= 19 * XAVGC9.1
A formula for C - XAVGC20 crossing down through its own 9-Period EMA could be written as:
11 * C + 8 * XAVGC20 < 19 * XAVGC9 AND 11 * C1 + 8 * XAVGC20.1 >= 19 * XAVGC9.1
And a formula for C - XAVGC20 crossing through its own 9-Period EMA in either direction could be written as:
SGN(11 * C + 8 * XAVGC20 - 19 * XAVGC9) <> SGN(11 * C1 + 8 * XAVGC20.1 - 19 * XAVGC9.1)
How to create a Personal Criteria Forumula (PCF)
Cascades of Moving Averages
PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!
-Bruce Personal Criteria Formulas TC2000 Support Articles
|