Download software Tutorial videos
Subscription & data-feed pricing Class schedule


New account application Trading resources
Margin rates Stock & option commissions

Attention: Discussion forums are read-only for extended maintenance until further notice.
Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

PCF %B*Bandwidth Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
rb73
Posted : Saturday, December 17, 2011 5:46:59 AM
Registered User
Joined: 10/13/2011
Posts: 10
I'm completely new to writing formulas but from the reading I've done, I can't find a way to make an indicator for %B times bandwidth.

Is this possible, please?
Bruce_L
Posted : Monday, December 19, 2011 8:05:37 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
It would depend on the settings of your Bollinger %B and Bollinger Bandwidth Indicators, but if both are set to 20,2.0, the formula could be written as:

((C - AVGC20) / SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / 4 + .5) * 4 * SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / AVGC20

Modelling Bollinger Bands (& Standard Deviation) in a TC PCF
PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!

-Bruce
Personal Criteria Formulas
TC2000 Support Articles
rb73
Posted : Tuesday, December 20, 2011 7:13:05 AM
Registered User
Joined: 10/13/2011
Posts: 10
Great service, thank you very much Bruce!
schwab.richard
Posted : Sunday, January 1, 2012 2:40:02 AM
Registered User
Joined: 4/4/2010
Posts: 2
QUOTE (Bruce_L)
It would depend on the settings of your Bollinger %B and Bollinger Bandwidth Indicators, but if both are set to 20,2.0, the formula could be written as:

((C - AVGC20) / SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / 4 + .5) * 4 * SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / AVGC20

Modelling Bollinger Bands (& Standard Deviation) in a TC PCF
PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!

When I tired to use the above PCF for MSFT the test gave me a 0.03 result instead of a 0.75 reading as indicated by the TC2000 %B 20 2 indicator.  Have I misapplied the PCF?

Rick S
schwab.richard
Posted : Sunday, January 1, 2012 10:32:56 AM
Registered User
Joined: 4/4/2010
Posts: 2

I am incorrect (missed a set of "()" in the formula). In the end I used:

(C - (AVGC20 - 2 * SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20))) / (4 * SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20))

I wanted to get this one right, as I intend to use adaptations of the PCF to calculate previous %B values.

Regret inconvenience.

Rick S

diceman
Posted : Sunday, January 1, 2012 1:18:28 PM
Registered User
Joined: 1/28/2005
Posts: 6,049
Rick,
You can use copy/paste with a posted PCF.

Just use: "Ctrl V" to paste it into telechart.



Thanks
diceman
Bruce_L
Posted : Monday, January 2, 2012 1:07:27 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
It is not missing any parentheses. It should be noted that this is a formula for Bollinger %B 20,2 times Bollinger Bandwidth 20,2. A formula for just the Bollinger %B 20,2 would be:

((C - AVGC20) / SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / 4 + .5)

While a formula for just the Bollinger Bandwidth 20,2 would be:

4 * SQR(ABS(C ^ 2 + C1 ^ 2 + C2 ^ 2 + C3 ^ 2 + C4 ^ 2 + C5 ^ 2 + C6 ^ 2 + C7 ^ 2 + C8 ^ 2 + C9 ^ 2 + C10 ^ 2 + C11 ^ 2 + C12 ^ 2 + C13 ^ 2 + C14 ^ 2 + C15 ^ 2 + C16 ^ 2 + C17 ^ 2 + C18 ^ 2 + C19 ^ 2 - 20 * AVGC20 ^ 2) / 20) / AVGC20

-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Users browsing this topic
Guest-1

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.