OPEN-SOURCE SCRIPT
ema_sw_alligator

A powerful and visually intuitive trading indicator that plots four exponential moving averages (EMA 8, 13, 48, 200) with customizable offsets and dynamic gradient visualization between the fast EMAs.
key features:
- four ema periods: displays ema 8, 13, 48, and 200 with customizable lengths
- customizable offsets: each ema can be shifted forward or backward in time (default: ema 200 offset 20, ema 48 offset 5, ema 13 offset 10, ema 8 offset 0)
- dynamic gradient system: visual color gradient between ema 8 and ema 13 that changes based on momentum:
-- green gradient when ema 8 crosses above ema 13 (bullish momentum)
-- red gradient when ema 8 crosses below ema 13 (bearish momentum)
- full customization:
- toggle individual ema visibility on/off
- customize colors for each ema line
- adjust gradient colors and transparency
- modify offset values for each ema
trading strategy:
ENTRY (Long)
- DAILY Chart
- 8 EMA crosses above 200 and 13 EMA
- Price remains above 200 EMA
- Break of Structure
Stay in:
- IF price stays above 8/13 and 48EMA after Entry
EXIT / STOP:
- Stop under recent swing low
- Exit when price crosses below 13 EMA IF under Entry
- Exit when price crosses below 48 EMA IF under Entry
trading applications:
- identify trend direction using the ema alignment
- spot potential entry points when ema 8 crosses ema 13 with gradient color confirmation
- use ema 48 and ema 200 as longer-term trend filters
- the offset feature helps anticipate potential support/resistance levels
- clear entry and exit rules based on EMA crossovers and price structure
settings overview:
- adjust ema lengths according to your trading style
- modify offsets to fine-tune the indicator's responsiveness
- customize colors for better visual clarity
- control gradient transparency to balance visibility and chart readability
perfect for swing traders, day traders, and anyone who uses moving average crossovers in their trading strategy. the visual gradient makes it easy to identify momentum shifts at a glance, while the clear trading rules provide a systematic approach to entries and exits.
key features:
- four ema periods: displays ema 8, 13, 48, and 200 with customizable lengths
- customizable offsets: each ema can be shifted forward or backward in time (default: ema 200 offset 20, ema 48 offset 5, ema 13 offset 10, ema 8 offset 0)
- dynamic gradient system: visual color gradient between ema 8 and ema 13 that changes based on momentum:
-- green gradient when ema 8 crosses above ema 13 (bullish momentum)
-- red gradient when ema 8 crosses below ema 13 (bearish momentum)
- full customization:
- toggle individual ema visibility on/off
- customize colors for each ema line
- adjust gradient colors and transparency
- modify offset values for each ema
trading strategy:
ENTRY (Long)
- DAILY Chart
- 8 EMA crosses above 200 and 13 EMA
- Price remains above 200 EMA
- Break of Structure
Stay in:
- IF price stays above 8/13 and 48EMA after Entry
EXIT / STOP:
- Stop under recent swing low
- Exit when price crosses below 13 EMA IF under Entry
- Exit when price crosses below 48 EMA IF under Entry
trading applications:
- identify trend direction using the ema alignment
- spot potential entry points when ema 8 crosses ema 13 with gradient color confirmation
- use ema 48 and ema 200 as longer-term trend filters
- the offset feature helps anticipate potential support/resistance levels
- clear entry and exit rules based on EMA crossovers and price structure
settings overview:
- adjust ema lengths according to your trading style
- modify offsets to fine-tune the indicator's responsiveness
- customize colors for better visual clarity
- control gradient transparency to balance visibility and chart readability
perfect for swing traders, day traders, and anyone who uses moving average crossovers in their trading strategy. the visual gradient makes it easy to identify momentum shifts at a glance, while the clear trading rules provide a systematic approach to entries and exits.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.