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 |

Setting an alert Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
BeastieBoy
Posted : Wednesday, September 11, 2013 10:55:16 AM
Registered User
Joined: 10/31/2011
Posts: 4

I'm new to writing scripts.  I want to set an alert so that when a 5 min candle closes within x percent of the daily 20 Period Moving average (simple).  I'm assuming I would need to write a scan condition.  But am unsure of how to differentiate the time frames.

BeastieBoy
Posted : Wednesday, September 11, 2013 11:04:16 AM
Registered User
Joined: 10/31/2011
Posts: 4

I tried setting an alert for GMCR 'Price Daily below Avg 20' and it alerted me incorrectly.  The AVG 20 is 83.35, price today has not been below 84.04.  Also got an error when I set an alert for 'Price Daily XDOWN Avg 20'  which also alerted at the incorrect price.  I'm trying to get TC2000 to alert me when the price is at the 20 period Daily moving Average.  

Bruce_L
Posted : Wednesday, September 11, 2013 11:11:56 AM


Worden Trainer

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

It is not possible to mix time frames within a single Personal Criteria Formula or condition. When you create or edit a formula in TC2000 version 12.3, there will be a Time Frame drop-down menu to set the time frame, but the time frame will apply to the entire formula.

You can create a Daily Condition Formula for price being within 5% of the daily 20-period simple moving average of price (this would mean that the close of the current 5-minute bars meets this requirement as well):

ABS(C / AVGC20 - 1) <= .05

But it is not possible to create a Condition Formula for the close of a particular 5-minute candle is within 5% of the daily 20-period simple moving average.

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

You can use an existing Condition Formula as the basis of an Alert for the current symbol by select More | Alerts | New Alert | Condition Alert and then selecting that condition from the Condition drop-down menu.

Setting Alerts in TC2000
Managing Alerts in the Alert Console

If you need to scan an entire WatchList for the condition however, you will need to use an EasyScan or Sort instead of an Alert.

Building a Scan with Multiple Conditions
Sorting with Chart Conditions



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Bruce_L
Posted : Wednesday, September 11, 2013 11:15:56 AM


Worden Trainer

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

QUOTE (BeastieBoy)
I tried setting an alert for GMCR 'Price Daily below Avg 20' and it alerted me incorrectly.  The AVG 20 is 83.35, price today has not been below 84.04.  Also got an error when I set an alert for 'Price Daily XDOWN Avg 20'  which also alerted at the incorrect price.  I'm trying to get TC2000 to alert me when the price is at the 20 period Daily moving Average.

Please contact technical support.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
BeastieBoy
Posted : Wednesday, September 11, 2013 12:16:05 PM
Registered User
Joined: 10/31/2011
Posts: 4

Thanks, Bruce.  I don't understand where I would need to put this in order to monitor/alert me.  You said it would be a 'Daily Condition Formula'.  I also don't understand why it would work intraday, as I thought that 'C' in the formula refers to 'Close', in this case of the Day's price.  Would this work intraday?

 

Bruce_L
Posted : Wednesday, September 11, 2013 2:00:47 PM


Worden Trainer

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

C refers to closing price if the bar is closed or the current price if the bar has not yet closed. Using a daily time frame for this works to identify if the current intraday bar meets the requirements because the current price of the current daily bar and the current price of the current intraday bar are exactly the same.

You can create a Condition Formula by selecting New | Condition Formula. Once you have saved the condition, you can use it as an Alert by following the directions given in my previous response. Select More | Alerts | New Alert | Condition Alert and then select the saved condition from the Condition drop-down menu. The two links mentioning alerts in my previous response are to videos demonstrating how to create and monitor alerts in more detail.



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