TradeStation’s COT (Commitment of Traders) Indicator:
TradeStation now includes the historic COT (Commitment of Traders) report in the form of an indicator.
If you can plot it then you can use it in a Strategy. The following code listing takes the Indicator code and with very few modifications turns it into a trading system.
{ Net positions of various groups of traders from the CFTC's weekly Commitments of Traders report. "Net" positions are calculated by taking the number of contracts that a group of traders is long and subtracting the number of contracts that that group of traders is short.
The user input "FuturesOnly_Or_FuturesAndOptions_1_or_2" determines whether the CFTC's "Futures Only" report is used, or the "Futures and Options" report is used to determine the positions of the various groups of traders. By default, the "Futures Only" report is used.
Plot1: Commercial traders' net position Plot2: Non-commercial traders' net position Plot3: Speculators' net positions, for speculators not of reportable size Plot4: Zero line
If an error occurs retrieving one of the values used by this study, or if the value is not applicable or non-meaningful, a blank cell will be displayed in RadarScreen or in the OptionStation assets pane. In a chart, no value will be plotted until a value is obtained without generating an error when retrieved. }
input: FuturesOnly_Or_FuturesAndOptions_1_or_2( 1 ) ; { set to 1 to use the CFTC's "Futures Only" report, set to 2 (or to any value other than 1) to use the "Futures and Options" report }
if oCommLongErr = fdrOk and oCommShortErr = fdrOk then begin CommNet = CommLong - CommShort ; Print ("CommNet ",commNet); end ;
if oNonCommLongErr = fdrOk and oNonCommShortErr = fdrOk then begin NonCommNet = NonCommLong - NonCommShort ; end ;
if oSpecLongErr = fdrOk and oSpecShortErr = fdrOk then begin SpecNet = SpecLong - SpecShort ; end ; If CommNet < 0 then sellShort tomorrow at open; If CommNet > 0 then buy tomorrow at open;
{ ** Copyright (c) 2001 - 2010 TradeStation Technologies, Inc. All rights reserved. ** ** TradeStation reserves the right to modify or overwrite this analysis technique with each release. ** }
COT Indicator Converted To Strategy
Line numbers 90 and 91 informs TS to take a long position if the Net Commercial Interests are positive and a short position if the Commercials are negative. I kept the original comments in place in case you wanted to see how the indicator and its associated function calls work. The linchpin of this code lies in the function call FundValue. This function call pulls fundamental data from the data servers and provides it in an easy to use format. Once you have the data you can play all sorts of games with it. This is just a simple system to see if the commercial traders really do know which direction the market is heading.
if you test this strategy on the ES you will notice a downward sloping 45 degree equity curve. This leads me to believe the commercials are trying their best to use the ES futures to hedge other market positions. If you go with the non Commercials you will see a totally different picture. To do this just substitute the following two lines:
If CommNet < 0 then sellShort tomorrow at open; If CommNet > 0 then buy tomorrow at open;
With:
If NonCommNet < 0 then sellShort tomorrow at open; If NonCommNet > 0 then buy tomorrow at open;
I said a totally different picture not a great one. Check out if the speculators know better.
George Pruitt’s Easing into EasyLangauge – Academy
A video-based approach to teaching EasyLanguage. Learn at your own pace.
Module #1
and Pattern Smasher 2024 too!
From the creator of the bestselling Easing into EasyLanguage series comes his latest project – Easing into EasyLanguage Academy. In this introductory course, George shows you to program a George Taylor Technique into a day trading system. You will start with a blank slate and learn everything you need to take advantage of Taylor’s Buy and Short – day techniques. Give the gift the keeps on giving – knowledge.
Can You Program This Trading Strategy?
Imagine this: On a buy day, you want to:
Enter: Place a buy order for tomorrow if the market:
Trades a certain amount below today’s low, and
Then travels back up to today’s low.
Protect: Use a protective stop at tomorrow’s low (before the buy stop is triggered).
Risk Manage: If the entry and exit levels are too large, limit your risk to a predefined amount.
Profit Secure: When a specific profit level is reached, implement a ratcheting trailing stop to lock in a percentage of the maximum open trade equity.
Time Manage: If still in the trade at a specific time of day, exit the position.
PURCHASE NOW AND GET PATTERN SMASHER 2024 FOR FREE!
Learn how to do this and then pick intelligent and robust paremeter sets.s
Get the Pattern Smasher Cheat Code to create this strategy. This is a 4 Pattern relationship based on the last three day’s closing relationships. You can learn more at George’s Digital Store.