Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 4/25/2012 Posts: 10
|
I am trying to write a PCF
max high of the stochastics over the last 15 days > 80 and lowest of stochs over 25 days > 35
I have tried
maxh15(stoc12.3) > 80 and minl25(stoc12.3)
This is not working.
Can you please help?
Thank you
|
|
Registered User Joined: 4/25/2012 Posts: 10
|
Sorry here is what I tried.
maxh15(stoc12.3) > 80
and
minl25(stoc12.3) > 35
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Assuming you are interested in the Simple Stochastic 12,3 %K, you could try the following:
MAX(STOC12.3,15) > 80 AND MIN(STOC12.3,15) > 35
PCF Formula Descriptions
Understanding Stochastics
Handy PCF example formulas to help you learn the syntax of PCFs!
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 4/25/2012 Posts: 10
|
Bruce,
Thank you!!!! That makes sense.
have a good one,
heath
|
|
Registered User Joined: 4/25/2012 Posts: 10
|
Bruce,
Is there a way to put THEN in a formula?
Such as Stoc higher than 90, then a min of 80% of the 90 stoc, then a stoc above 90?
MAX(STOC12.3,15) > 90 THEN
MIN(STOC12.3,15) > (max high stoc*.80) THEN
MAX(STOC12.3,15) > 90
Thank you
Heath
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
In general, no. You cannot create sequences of Conditions of unknown length in a specific order.
You could check for highest Stochastic of the first five bars being above 90, the lowest Stochastic of the next five bars being above 80% of the highest Stochastic of the first five bars and the highest Stochastic of the last five bars being above 90:
MAX(STOC12.3.10,5) > 90 AND MIN(STOC12.3.5,5) > .8 * MAX(STOC12.3.10,5) AND MAX(STOC12.3,5) > 90
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 4/25/2012 Posts: 10
|
Bruce,
Great, I'll try that.
Thanks again.
Heath
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You're welcome.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Guest-1 |