Registered User Joined: 2/8/2007 Posts: 39
|
If I run this PCF it will only sort daily data
STOC17.3 > 50 AND ABS(((STOC17.3 + STOC8.5 + STOC5.3) / 3) - STOC17.3) < 3
How would you have to write this or what functionality of the software is available to allow you to scan for weekly or other timeframes?
What am I missing?
Thanks again
|
Registered User Joined: 1/28/2005 Posts: 6,049
|
The simplest method would be to create a
custom indicator (percent true). Make you chart
a weekly time frame.
Click on the indicator and choose sort by actual
value.
(for other time frames choose other bar lengths)
You may be interested in this:
Thanks
diceman
|
Registered User Joined: 2/8/2007 Posts: 39
|
That's a good idea but I want to put the PCF in a column under a tab on the lefthand side.
Thanks.
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
mjwilt,
Your particular formula:
STOC17.3 > 50 AND ABS(((STOC17.3 + STOC8.5 + STOC5.3) / 3) - STOC17.3) < 3
Can be converted to a Weekly Personal Criteria Formula as follows:
(STOC85 + STOC85.1.5 + STOC85.1.10) / 3 > 50 AND ABS(((STOC40 + STOC40.1.5 + STOC40.1.10 + STOC40.1.15 + STOC40.1.20) / 5 + (STOC25 + STOC25.1.5 + STOC25.1.10 - 2 * (STOC85 + STOC85.1.5 + STOC85.1.10)) / 3) / 3) < 3
If you are converting formulas based entirely on the Open, High, Low, Close and Volumes of weekly bars, yes. I'll put the daily version followed by the weekly equivalent:
For the Open, multiply the days ago parameter by 5 and add 4 to get the weekly version.
O = O4
O1 = O9
O2 = O14
For the High, H is replaced by MAXH5 and if there is a days ago parameter in the daily version, multiply it by 5 and separate it from MAXH5 with a '.'.
H = MAXH5
H1 = MAXH5.5
H2 = MAXH5.10
The Low is treated very much like the High. L is replaced by MINL5 and if there is a days ago parameter in the daily version, multiply it by 5 and separate it from MINL5 with a '.'.
L = MINL5
L1 = MINL5.5
L2 = MINL5.10
The Close is probably the simplest. Just multiply the days ago parameter in the daily version by 5 to get the weekly version.
C = C
C1 = C5
C2 = C10
Volume is an interesting case. To get the actual Volume for a weekly bar (in Blocks of 100), you would need to multiply the Average Volume by 5. So V would be replaced by AVGV5 and if there is a days ago parameter in the daily version, multiply it by 5 and separate it from MINL5 with a '.' just like with the High and Low. But add *5 to the end of each weekly version whether or not there is a days ago parameter.
V = AVGV5*5
V1 = AVGV5.5*5
V2 = AVGV5.10*5
That said, if you are just comparing one Volume to another, there really isn't a reason to multiply it by 5 at all:
AVGV5*5 > AVGV5.5*5
Will return the same result as:
AVGV5 > AVGV5.5
Things can get a lot more complicated for weekly versions of some indicators. In same cases, it is not possible to write a weekly version (a weekly TSV for example). You may wish to review the following:
How to create a Personal Criteria Forumula (PCF)
PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!
Customize the Information Displayed in the WatchList
-Bruce Personal Criteria Formulas TC2000 Support Articles
|