Friday, December 14, 2012

Advanced Examples for our Formula Editor Part 3

I recently posted some examples of how I use our formula editor.  I got a lot of good feedback.  If you missed Parts 1 and 2, you can read Part 1 here, and Part 2 here. Several people asked if there are any secrets that we haven't shared yet.  Here are more examples, including a few secrets.  Shhh!

Dollar Volume

v_up_5*[Price]
[Price]*[TV]
The first line reports the approximate number of dollars traded for this stock in the last 5 minutes.  The second line reports the number of dollars traded today.  (We have a standard filter for the average dollar volume.)  This is just a small variation on a common idea.  That's the beauty of the formulas.  Formulas offer a lot more options than you can get from just the GUI.


More Tests

sin([Dec])
cos(bid)+tan(ask)+asin(sma_2_5)+acos(sma_5_5)+atan(sma_15_5)
Some users requested trigonometry functions.  I'm not sure what these are used for.  My job was just to make sure they were available.


Next Support or Resistance

[=u]
[=p]
These only makes sense for new high and low alerts.  These will report the same value that you see in the text description of the alerts.  The first one will port the next support or resistance level.  The second one will report the amount of change since the last new high or low.

Items that start with [= are new.  We don't have any documentation yet as they are somewhat complicated.  These all apply to the text that you see in the descriptions of various alerts.  There are a lot more that I haven't listed here.  If you need help, contact brad@trade-ideas.com.


Hidden Filters

p_up_1
v_up_1
[Dec]
These are available as normal filters in an alert window.  Normally these do not appear in the top list.  However, if you really want these, you can have them.  Just punch in one of these formulas and it will appear at the bottom of your config window, with all of your other custom formulas.


Smart Volume

[RV]??[PV]/100
This solves an interesting problem.  Relative volume is generally preferred to percent volume because the former takes the time of day into account.  The problem is that relative volume isn't available in the pre-market.  This filter will use the better one if it's available, and the other one if it is not.

Notice that we divide the percent volume by 100.  Relative volume is a ratio.  When we divide percent volume by 100, that changes it from a percent to a ratio.  Now the two are more similar.


Satan

Formula not Available
This is an interesting one.  It's very special and it can't be written out in our normal formula language.  But if you ask, our support people can add it for you.

This is a special type of random number generator.  This is useful to avoid curve fitting.  The idea is to optimize your strategy using a randomly selected subset of the market.  When you think you're done, try your strategy on the rest of the market.  That gives you a better idea if you've found something real.

We use this and other tricks in our execution consulting.

No comments: