| Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 12/29/2004 Posts: 11
|
I'm looking for a pcf that will plot the moving average of oscillators (used in metatrader 4) as a histogram in V12 using 12-26-9. It is the difference between the 12/26 histogram and the 9 period moving average of the signal line. It is plotted above and below a zero line. Then another pcf is needed to find the crossings of the zero line from above and from below. Timeframe would be 4hr, daily, and weekly. Thanks
|
|
Registered User Joined: 1/28/2005 Posts: 6,049
|
Thats the MACD histogram, its already a built-in indicator.
Thanks
diceman
|
|
Registered User Joined: 12/29/2004 Posts: 11
|
Thanks for responding. It is related to the MACD with the same parameters. But the OsMA is the difference between the 9 period signal line and the 12/26 histogram. It is plotted as another histogram oscillating around the zero line. When the signal line is crossing the histogram on the MACD, the OsMA is crossing the zero line. I can write a pcf for the 12/26 histogram, but I'm having a problem subtracting the 9 period moving average of the MACD to get the new histogram. Thanks
|
|
Registered User Joined: 1/28/2005 Posts: 6,049
|
QUOTE (sunstone) Thanks for responding. It is related to the MACD with the same parameters. But the OsMA is the difference between the 9 period signal line and the 12/26 histogram. It is plotted as another histogram oscillating around the zero line. When the signal line is crossing the histogram on the MACD, the OsMA is crossing the zero line. I can write a pcf for the 12/26 histogram, but I'm having a problem subtracting the 9 period moving average of the MACD to get the new histogram. Thanks
What you’ve described is the MACD histogram.
Thanks
diceman
|
|
Registered User Joined: 12/29/2004 Posts: 11
|
I understand it is basically the MACD, but it is a modifcation of it I would like to plot as an indicator.
Please chk out the website below
http://www.fxstrategy.com/video/forex-trading-indicators/moving-average-of-oscillator-osma-67.html
|
|

 Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You may want to review the Understanding MACD topic.
I've read through a bunch of topics on OSMA and even looked at some code for OSMA. As far as I can tell, it is just as you describe it, the difference between the raw MACD and its Moving Average Signal Line. This would mean diceman is correct and OSMA is the same as the MACD Histogram indicator in TC2000 version 12.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
 Administration
Joined: 9/30/2004 Posts: 9,187
|
I don't understand why they say it's a modification of MACD unless they're misunderstanding how MACD is calculated in the first place. There has been some confusion about what a MACD histogram is. Some think it is just the MACD line (diff between two moving averages) plotted as a histogram which is basically just a plot style. But MACD is always plotted with a trigger line, and a MACD histogram plots the difference between the MACD line and its trigger line, and is traditionally displayed as a histogram.
|
|
Registered User Joined: 12/29/2004 Posts: 11
|
ok, Thanks
|
|
Registered User Joined: 12/29/2004 Posts: 11
|
Thanks, I've done some more research and the MACD histogram is what I am looking for. Do you have a pcf for the 4hr, daily and weekly timeframes?
Thanks again,
|
|

 Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
Assuming you are using a MACD Histogram 12,26,9 in TC2000 version 12, one way to write an Indicator Formula would be:
XAVGC12 - XAVGC26 - XAVG(XAVGC12,9) + XAVG(XAVGC26,9)
The formula would be the same for any Time Frame. You would just adjust the Time Frame of the Indicator Formula using the Time Frame drop-down menu when it is created or edited (you can also adjust the Time Frame when the Indicator Formula is used as a WatchList Column or Scan Condition).
Understanding MACD
PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!
It should be noted that it is actually more efficient to just click on a charted MACD Histogram indicator and select Add column to WatchList or Create Condition than to create an Indicator Formula or Condition Formula.
Indicators, Sorting & Scanning
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 12/29/2004 Posts: 11
|
Works great, just what I wanted. Thanks for your patience Bruce and Diceman
|
|

 Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You're welcome. Our pleasure.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
|
Guest-1 |