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 |

WEEKLY CHARTS Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
bboisky
Posted : Saturday, August 3, 2013 2:49:11 AM
Registered User
Joined: 10/7/2004
Posts: 25

I AM TRYING TO DO A MACD 5/12 CROSSING 0 UP WITHIN THE LAST TWO WEEKS USING WEEKLY CHARTS AND THE FOLLOWING: (XAVGC5.10 - XAVGC12.10) < 0 AND (XAVGC5.5 - XAVGC12.5) > 0. THIS PCF IS NOT WORKING FOR ME ON WEEKLY CHARTS--PLEASE TELL ME WHAT I AM  DOING WRONG?  FURTHER, I WOULD LIKE TO GET THE SCAN  RESULTS ONE DAY AGO IF POSSIBLE ? THANKS, BOBBY B. 

Bruce_L
Posted : Tuesday, August 6, 2013 8:38:26 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

Your formula appears to be looking for a crossup between 2-weekly bars ago and 1-weekly bar ago. You have multiplied the period of the offset by 5, but you have not multiplied the periods of the MACD itself by 5. Doing so would result in:

XAVGC25.5 > XAVGC110.5 AND XAVGC25.10 <= XAVGC110.10

This is actually a pretty decent approximation, but it will not match the charts.

In TC2000 version 7, the weekly charts are comprised of rolling 5-trading day bars and Personal Criteria Formulas are always calculated using daily bars (although Custom PCF Indicators use the bars on the chart for their calculations).

Another consequence of the rolling 5-trading day bars is that moving averages of the close have absolutely nothing to do with yesterday, 2-days ago, 3-days ago or 4-days ago. A 2-Period Simple Moving Average on a weekly chart would skip all of those bars for example and be calculated using the current price and the closing price of 5-days ago.

If we take this into account, we need to manually expand the moving average by sampling price only once every 5-days. This results in the following approximation which should be better at matching the charts than the shorter formula above (but the above formula may be better in that it uses more information and his granularity in its calculations).

.333559 * (C5 + 2 / 3 * (C10 + 2 / 3 * (C15 + 2 / 3 * (C20 + 2 / 3 * (C25 + 2 / 3 * (C30 + 2 / 3 * (C35 + 2 / 3 * (C40 + 2 / 3 * (C45 + 2 / 3 * (C50 + 2 / 3 * (C55 + 2 / 3 * (C60 + 2 / 3 * (C65 + 2 / 3 * (C70 + 2 / 3 * (C75 + 2 / 3 * (C80 + 2 / 3 * (C85 + 2 / 3 * (C90)))))))))))))))))) > 0.153984303064341 * (C5 + 11 / 13 * (C10 + 11 / 13 * (C15 + 11 / 13 * (C20 + 11 / 13 * (C25 + 11 / 13 * (C30 + 11 / 13 * (C35 + 11 / 13 * (C40 + 11 / 13 * (C45 + 11 / 13 * (C50 + 11 / 13 * (C55 + 11 / 13 * (C60 + 11 / 13 * (C65 + 11 / 13 * (C70 + 11 / 13 * (C75 + 11 / 13 * (C80 + 11 / 13 * (C85 + 11 / 13 * (C90 + 11 / 13 * (C95 + 11 / 13 * (C100 + 11 / 13 * (C105 + 11 / 13 * (C110 + 11 / 13 * (C115 + 11 / 13 * (C120 + 11 / 13 * (C125 + 11 / 13 * (C130 + 11 / 13 * (C135 + 11 / 13 * (C140 + 11 / 13 * (C145 + 11 / 13 * (C150 + 11 / 13 * (C155 + 11 / 13 * (C160 + 11 / 13 * (C165 + 11 / 13 * (C170 + 11 / 13 * (C175 + 11 / 13 * (C180 + 11 / 13 * (C185 + 11 / 13 * (C190 + 11 / 13 * (C195 + 11 / 13 * (C200 + 11 / 13 * (C205 + 11 / 13 * (C210)))))))))))))))))))))))))))))))))))))))))) AND .333559 * (C10 + 2 / 3 * (C15 + 2 / 3 * (C20 + 2 / 3 * (C25 + 2 / 3 * (C30 + 2 / 3 * (C35 + 2 / 3 * (C40 + 2 / 3 * (C45 + 2 / 3 * (C50 + 2 / 3 * (C55 + 2 / 3 * (C60 + 2 / 3 * (C65 + 2 / 3 * (C70 + 2 / 3 * (C75 + 2 / 3 * (C80 + 2 / 3 * (C85 + 2 / 3 * (C90 + 2 / 3 * (C95)))))))))))))))))) <= 0.153984303064341 * (C10 + 11 / 13 * (C15 + 11 / 13 * (C20 + 11 / 13 * (C25 + 11 / 13 * (C30 + 11 / 13 * (C35 + 11 / 13 * (C40 + 11 / 13 * (C45 + 11 / 13 * (C50 + 11 / 13 * (C55 + 11 / 13 * (C60 + 11 / 13 * (C65 + 11 / 13 * (C70 + 11 / 13 * (C75 + 11 / 13 * (C80 + 11 / 13 * (C85 + 11 / 13 * (C90 + 11 / 13 * (C95 + 11 / 13 * (C100 + 11 / 13 * (C105 + 11 / 13 * (C110 + 11 / 13 * (C115 + 11 / 13 * (C120 + 11 / 13 * (C125 + 11 / 13 * (C130 + 11 / 13 * (C135 + 11 / 13 * (C140 + 11 / 13 * (C145 + 11 / 13 * (C150 + 11 / 13 * (C155 + 11 / 13 * (C160 + 11 / 13 * (C165 + 11 / 13 * (C170 + 11 / 13 * (C175 + 11 / 13 * (C180 + 11 / 13 * (C185 + 11 / 13 * (C190 + 11 / 13 * (C195 + 11 / 13 * (C200 + 11 / 13 * (C205 + 11 / 13 * (C210 + 11 / 13 * (C215))))))))))))))))))))))))))))))))))))))))))

PCF Formula Descriptions
Handy PCF example formulas to help you learn the syntax of PCFs!
Cascades of Moving Averages



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
bboisky
Posted : Thursday, August 8, 2013 10:19:26 PM
Registered User
Joined: 10/7/2004
Posts: 25

BRUCE, THX FOR YOUR MACD WEELY MACD HELP. bobby b

 

Bruce_L
Posted : Friday, August 9, 2013 8:14:15 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

You're welcome.



-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.