Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 11/29/2006 Posts: 181
|
Hi.
I would like to use Williams %R 30 as a custom indicator. I would appreciate the formula if it is possible.
Thank you
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Williams %R is just the raw Stochastic minus one hundred (it runs from -100 to 0 instead of 0 to 100). So to create a Custom Indicator for a 30-Period Williams %R:
Select Chart Template | Add Indicator | Indicator.
- Visible: Checked
- Center Zero Line: Unchceked
- Plot using price scale: Unchecked
- Smoothing Average: 1
- Average Type: Doesn't matter (because the Smoothing Average is 1)
- Indicator Formula: STOC30 - 100
The result will be AutoScaled in that it will not necessarily run from -100 to 0. The highest value the Custom Indicator reaches in the visible portion of the Chart will be at the top of the Chart while the lowest value the Custom Indicator reaches will be at the bottom of the Chart. I do not know of a practical automated method to add lines at -20 and -80.
Another option might be to just add the built in Stochastic indicator and adjust it mentally. The Stochastic will run from 0 to 100 while the Williams %R will be autoscaled (although this may not matter with a short enough Period vs Zoom). It will have lines at 20 and 80 by default.
Plotting Custom Indicators with Examples
Understanding Stochastics
How to create a Personal Criteria Forumula (PCF)
PCF Formula Descriptions
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 11/29/2006 Posts: 181
|
Thank you Bruce. Works like a charm.
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You're welcome.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 12/17/2004 Posts: 143
|
Bruce,
I'm using your Wms %R, and it's working fine. I'd also like to program a SL related to it, and am confident it'll be easy for you to tell me what I'm doing wrong.
I want the following CI to give me a zero if the three conditions aren't all true, and yesterday's low if they are all true:
(STOC30.1.1>80 and c>h1 and L>L1)*(-1)*L1
It does, but when I multiply it by 100, it gives me -.02 (see stock = MA, daily, on 5/2/07) when 1 or more conditions is false.
Shouldn't it be giving me a zero? Because my ulitmate goal is to add to it the same test on 2-5 days back, it can end up being 4 cents off. Has TC2K got a rounding function I need to use, so that a zero is really a zero?
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
jfh123,
TeleChart uses single precision binary floating-point format for its numbers. This means integers (such as zero) are not going to be perfectly represented. While you can get something fairly close, the nearest number to zero that can be represented is still a non-zero number.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 12/17/2004 Posts: 143
|
Now that I think about it, 4 cents is not gonna make or break any strategy. Thanks for your reply.
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
jfh123,
You're welcome.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 7/12/2010 Posts: 87
|
A question on the Percent R how can I get the lines at -20 and -80 on the chart
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
iceman70028,
As stated in my original response in this topic, I do not of a practical automated method to add lines at -20 and -80.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 7/12/2010 Posts: 87
|
How do I put together a scan to when the stock crosses the -80 and -20
|
|
Registered User Joined: 7/12/2010 Posts: 87
|
this was for percent r
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Since the formula for a 30-Period Williams %R is:
STOC30 - 100
The formula for it crossing up through -20 would be:
STOC30 - 100 > (-20) AND STOC30.1.1 - 100 <= (-20)
The formula for it crossing down through -20 would be:
STOC30 - 100 < (-20) AND STOC30.1.1 - 100 >= (-20)
The formula for it crossing up through -80 would be:
STOC30 - 100 > (-80) AND STOC30.1.1 - 100 <= (-80)
The formula for it crossing down through -80 would be:
STOC30 - 100 < (-80) AND STOC30.1.1 - 100 >= (-80)
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 7/12/2010 Posts: 87
|
Is there a way to do volume profile indicator
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
I do not know of a way to create a Volume Profile Indicator in either TeleChart or StockFinder.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Guest-1 |