OPEN-SOURCE SCRIPT
Updated ICT Commitment of Traders° by toodegrees

Description:
The Commitment of Traders (COT) is a valuable raw data report released weekly by the Commodity Futures Trading Commission (CFTC). This report offers insights into the current long and short positions of three key market entities:
The concept of utilizing the COT data as a strategic trading tool was first introduced by Larry Williams, who emphasized the importance of monitoring Commercial Speculators – large corporate producers or consumers of commodities.
The Inner Circle Trader (ICT) prompts us to delve deeper into this data. While we can easily determine their Net Position (also referred to as the Main Program) by subtracting Commercial Short Positions from the Commercial Long Positions, this calculation doesn't reveal their ongoing Hedge Program.
Merely following the Main Program won't provide a trading edge. Aligning with the Hedge Program can be an invaluable weapon in your trading arsenal.
The Commercial Speculators' Hedge Program can be unveiled by examining the highest and lowest reading of their Net Position over a chosen time period and setting a new "zero line" between these extremes. This process generates a novel "COT Graph" providing a detailed understanding of the Commercial Speculators' current market activity.
When the Hedge Program, Seasonality, and Open Interest are cross-referenced with Institutional Orderflow, a trader can construct a very clear medium-to-long-term market narrative.
Features:
Additionally, by following the included instructions, you can augment your table with COT data from multiple markets. This extra information can help monitor correlated markets and develop a more robust market narrative:

The Commitment of Traders (COT) is a valuable raw data report released weekly by the Commodity Futures Trading Commission (CFTC). This report offers insights into the current long and short positions of three key market entities:
- Commercial Traders (usually represented in red)
- Large Traders (typically depicted in green)
- Small Speculator Traders (commonly shown in blue)
The concept of utilizing the COT data as a strategic trading tool was first introduced by Larry Williams, who emphasized the importance of monitoring Commercial Speculators – large corporate producers or consumers of commodities.
The Inner Circle Trader (ICT) prompts us to delve deeper into this data. While we can easily determine their Net Position (also referred to as the Main Program) by subtracting Commercial Short Positions from the Commercial Long Positions, this calculation doesn't reveal their ongoing Hedge Program.
Merely following the Main Program won't provide a trading edge. Aligning with the Hedge Program can be an invaluable weapon in your trading arsenal.
The Commercial Speculators' Hedge Program can be unveiled by examining the highest and lowest reading of their Net Position over a chosen time period and setting a new "zero line" between these extremes. This process generates a novel "COT Graph" providing a detailed understanding of the Commercial Speculators' current market activity.
When the Hedge Program, Seasonality, and Open Interest are cross-referenced with Institutional Orderflow, a trader can construct a very clear medium-to-long-term market narrative.
Features:
- Access COT Data for the Commercial Speculators via Tradingview's reliable data source
- Automate calculations and display the 3-month, 6-month, 12-month, 2-year, and 3-year Hedge Program
- Define your own Custom Time Range for the Hedge Program
- Display the Main Program and all Hedge Programs in an easy-to-understand table format
Additionally, by following the included instructions, you can augment your table with COT data from multiple markets. This extra information can help monitor correlated markets and develop a more robust market narrative:
Release Notes
Update: added option to hide multi-market data (once enabled through code modifications)Release Notes
Corrected instructionsRelease Notes
Update: added error handling by limiting the display of COT Data to the Daily Timeframe or higher – Lines 12 to 15Release Notes
Bug Fix: hiding COT Data did not hide boxes, fixedRelease Notes
Bug fix: COT market cell for the Info table was reporting wrong ticker, fixed.Release Notes
Added Auto-Timeframe FeatureOpen-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
For quick access on a chart, add this script to your favorites — learn more here.
homo faber fortunæ suæ
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
For quick access on a chart, add this script to your favorites — learn more here.
homo faber fortunæ suæ
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.