Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 1/24/2005 Posts: 107
|
Is it possible to make a custom indicator from this. ( close - open ) divided by ( high - low ) times the ( daily volume ). If the opening price is lower than the close, your net volume figure for the day will be positive and add to the previous days A/D line. If the close is below the opening,it is a negative and subtracted from previous days A/D line. You arbitrarily chose a base number, say 5,000 and then begin the process like an on balance volume line is constructed.
If stocks opening and closing are the same. No change is needed,carry forward yesterdays A/D line figure.
If the opening price is the same as the daily high and the closing price the same as the daily low, just subtract the days total volume from the previous days A/D figure.
if the opening price and the daily low are the same and the close and the high are the same, just add the days total volume to the previous days A/D figure. Thank you
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Please try the following:
Select Chart Template | Add Indicator | Cumulative. -Visible: Checked -Smoothing Average: 1 -Up Condition: C < C + 1 -Down Condition: C > C + 1 -Value To Add/Substract: V * (C - O) / (H - L + .00001)
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 1/24/2005 Posts: 107
|
Bruce I see the last part of the indicator is similar to what I have in the question above, what is the .00001 for. And how does this formula know if the close is higher than the open to add to the indicator or if the close is below the open to subtract from the indicator? Does it have something to do with the up condition and the down condition, if so it should be based on the open to the close not the close to the close ? Also once I have created this indicator can I save it or some how keep it on the list of indicators to use ? Thank you for your help
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
QUOTE (doji) what is the .00001 for. To prevent divide by zero errors.
QUOTE (doji) And how does this formula know if the close is higher than the open to add to the indicator or if the close is below the open to subtract from the indicator? C - O is positive if C > O and negative if C < O.
QUOTE (doji) Does it have something to do with the up condition and the down condition, if so it should be based on the open to the close not the close to the close ? It adds when the Up Condition is True and subtracts when the Down Condition is True, but the Up Condition is designed in this particular case to always be True and the Down Condition is always False so the value will always be added. If it was added when C > O and subtracted when C < O the indicator would always go up (unless C = O) and never go down.
QUOTE (doji) Also once I have created this indicator can I save it or some how keep it on the list of indicators to use ? If you Save the Chart Template to which you have added the Custom Cumulative Indicator, it will remain on the Chart Template, but it will not be added to your list of indicators to add to other Chart Templates.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 1/24/2005 Posts: 107
|
Thank you for your help and explanations.
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You're welcome.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 10/7/2004 Posts: 3
|
Bruce: Can you write a custom formula for the following:
ADJHIGH:=If(HIGH<=Ref(CLOSE,-1),Ref(CLOSE,-1),HIGH);
ADJLOW:=If(LOW>=Ref(CLOSE,-1),Ref(CLOSE,-1),LOW);
ADJRANGE:=ADJHIGH-ADJLOW;
DBI:=((CLOSE-ADJLOW)/ADJRANGE)*VOLUME*(CLOSE-ADJLOW);
DSI:=((ADJHIGH-CLOSE)/ADJRANGE)*VOLUME*(ADJHIGH-CLOSE);
OBDI:=DBI-DSI;
Mov(OBDI,20,E)
. It is written in MetaStock Language; but it's all math and shouldn't be too difficult. As for the abbreviations used, they are:
ADJHIGH = ADJUSTED HIGH, ADJLOW = ADJUSTED LOW, ADJRANGE = ADJUSTED RANGE, DBI = DAILY BUYING INTENSITY, DSI = DAILY SELLING INTENSITY, OBDI = ON BALANCE DAILY INTENSITY. Mov is a moving average. Ref refers to the past. Ref(Close,-1) refers to yesterday's close.
Thank you, Bobc
|
|
Registered User Joined: 2/19/2006 Posts: 89
|
QUOTE (Bruce_L) Please try the following:
Select Chart Template | Add Indicator | Cumulative. -Visible: Checked -Smoothing Average: 1 -Up Condition: C < C + 1 -Down Condition: C > C + 1 -Value To Add/Substract: V * (C - O) / (H - L + .00001)
Bruce what does this indicate? I plotted it in my bottome window and visually it looks identical to my 28 bar TSV which I have in the next window right above it.
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Deion, The Custom Cumulative Indicator in this topic represents Volume times the difference between the Close and Open as a percentage of the Range for the Period added to previous values for this calculation. I can't offer an interpretation advice for this indicator.
When I plot this and a 28-Period TSV in the same window, they sometimes have a somewhat similar shape, but frequently don't and never seem to actually overlap (which would make sense since one is a Cumulative Indicator based on the formula given and the other is a Moving Average of the raw TSV).
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Guest-1 |