Registered User Joined: 12/29/2013 Posts: 71
|
Bruce can a PCF be written to display a column when the ADX(14) slope, is either negative or positve?
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
There really isn't a good way to write a PCF for this. Your best option is going to be to click on the ADX indicator and select Create Scan Condition.
Create Conditions from Your Chart (5:25)
PCF for Wilder's Directional Movement DMI-crossovers
PCF for Wilder's DX, and/or a CI for Wilder's ADX
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
Registered User Joined: 12/29/2013 Posts: 71
|
Ok Thanks Bruce.
|
Registered User Joined: 5/3/2007 Posts: 10
|
Is there a way to scan for the slope of a moving average ie 50 dMA =45 degrees.
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
It is not possible to calculate the slope as an angle. This is because the angle can change based on things like scroll, zoom, other indicators being plotted and even the aspect ratio of the pane in which it is plotted.
A net slope from the previous bar to the current bar could be written as follows.
AVGC50 - AVGC50.1
While the percent slope from one bar to the next can be written as follows.
100 * (AVGC50 / AVGC50.1 - 1)
You could adjust this to say 10 bars by adjusting the bars ago parameter. So the net slope would be:
AVGC50 - AVGC50.10
And the percent slope would be:
100 * (AVGC50 / AVGC50.1 - 1)
Once you go to looking at multiple bar slopes, you could calculate a linear regression slope as well.
(4.5 * AVGC50 + 3.5 * AVGC50.1 + 2.5 * AVGC50.2 + 1.5 * AVGC50.3 + .5 * AVGC50.4 - .5 * AVGC50.5 - 1.5 * AVGC50.6 - 2.5 * AVGC50.7 - 3.5 * AVGC50.8 - 4.5 * AVGC50.9) / 82.5
And express this a percentage of the moving average (or some other basis)
100 * (4.5 * AVGC50 + 3.5 * AVGC50.1 + 2.5 * AVGC50.2 + 1.5 * AVGC50.3 + .5 * AVGC50.4 - .5 * AVGC50.5 - 1.5 * AVGC50.6 - 2.5 * AVGC50.7 - 3.5 * AVGC50.8 - 4.5 * AVGC50.9) / 82.5 / AVGC50
Using Linear Regression vs Classical Peaks/Valleys for Divergence Analysis
-Bruce Personal Criteria Formulas TC2000 Support Articles
|