Measuring Moving Average Ribbon Compression


Well-known member
2019 Donor
Hi Everyone,

I was about to embark in the development of a indicator or button, that attempts to measure detect moving average ribbon compressions, when there are multiple moving average tightly together to detect potential choppy trading period when using moving average ribbons for trading. As an example trading the Slim Ribbon, I want to detect potential compression to avoid trading the underlying.

I was thinking of subtracting the absolute value of the (fast - superfast) + (slow - fast), and take the value thru a moving average to detect compression.

As anyone coded or have a suggestion on the best approach to accomplish this?

Thanks in advance,


Well-known member
2019 Donor
Thanks Ben. Will compare the results of the side way indicator and the compression and will share the results.

What I was thinking is getting a moving average of the absolute subtraction and additions of the distance of price of the ribbon, then getting the highestall, then using that to divide and calc a percentage or a ratio of compression relative to all of the moves in the average.



Well-known member
2019 Donor
Thanks Ben - Here is an example of MSFT 2 Hours Using EMA Ribbon




Note the gray square areas, looking for a way to be able to detect ribbon compression during these periods or ratio out how wide the ribbons are contract or expanding state.

Last edited:


New member
I am also looking for a script that can sort out from a Watchlist during GMMA's MA ribbon compression .. hope you guys can help as I have zero programming knowledge

Similar threads

The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
  • Exclusive indicators
  • Proven strategies & setups
  • Private Discord community
  • ‘Buy The Dip’ signal alerts
  • Exclusive members-only content
  • Add-ons and resources
  • 1 full year of unlimited support

Frequently Asked Questions

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?
VIP members get exclusive access to these proven and tested premium indicators: Buy the Dip, Advanced Market Moves 2.0, Take Profit, and Volatility Trading Range. In addition, VIP members get access to over 50 VIP-only custom indicators, add-ons, and strategies, private VIP-only forums, private Discord channel to discuss trades and strategies in real-time, customer support, trade alerts, and much more. Learn all about VIP membership here.
How can I access the premium indicators?
To access the premium indicators, which are plug and play ready, sign up for VIP membership here.