OPEN-SOURCE SCRIPT
Mickey's EMA

Mickey’s EMA is a lightweight, overlay indicator that combines two Exponential Moving Averages (EMAs) with automatic entry, stop-loss and target visual signals—plus dynamic JSON alerts for seamless webhook integration. It’s designed for both day-traders and swing-traders who want clear, on-chart cues and fully-customizable risk parameters.
🔍 Overview
⚙️ Inputs
| Setting | Default | Description |
| ------------------------ | ------- | ----------------------------------------------- |
| **Fast EMA Length** | 20 | Period for the faster EMA. |
| **Slow EMA Length** | 200 | Period for the slower EMA. |
| **Price Source** | Close | Data series to calculate EMAs on. |
| **Custom Stop Loss %** | 0.1% | Stop-loss level as a percentage of entry price. |
| **Target %** | 0.5% | Profit-target level as a percentage of entry. |
| **Show Entry/SL/Target** | ON | Toggle all entry, SL and target visuals. |
📊 What It Plots
🔔 Alerts & Webhooks
Pine Script®
Use these alerts to integrate with bots, chat systems, manual, or any webhook-driven workflow.
🚀 Why Use Mickey’s EMA?
Add Mickey’s EMA to your TradingView chart today and get instant, aesthetically-pleasing guidance on trend entries, risk exits, and profit targets—all in one elegant overlay.
🔍 Overview
- Dual EMAs (fast & slow) to capture trend changes.
- Automated “BUY” / “SELL” markers at every EMA crossover.
- Customizable Stop-Loss % and Target % levels, plotted as ❌ and 🎯 bubbles.
- “SL Hit (Custom)” if the opposite EMA crossover occurs before price touches your stop level.
- JSON-formatted alerts containing ticker, instrument type, timeframe, trend (“CE” for bullish, “PE” for bearish), and price—ready for webhooks.
⚙️ Inputs
| Setting | Default | Description |
| ------------------------ | ------- | ----------------------------------------------- |
| **Fast EMA Length** | 20 | Period for the faster EMA. |
| **Slow EMA Length** | 200 | Period for the slower EMA. |
| **Price Source** | Close | Data series to calculate EMAs on. |
| **Custom Stop Loss %** | 0.1% | Stop-loss level as a percentage of entry price. |
| **Target %** | 0.5% | Profit-target level as a percentage of entry. |
| **Show Entry/SL/Target** | ON | Toggle all entry, SL and target visuals. |
📊 What It Plots
- Fast EMA (blue) & Slow EMA (white) overlayed on price.
- BUY 🟢 label below bar when Fast EMA crosses above Slow EMA.
- SELL 🔴 label above bar when Fast EMA crosses below Slow EMA.
- ❌ (Custom) bubble at entry price if an opposite EMA crossover occurs before price hits your custom stop-loss.
- ❌ bubble at the stop-loss price when price actually breaches the stop level.
- 🎯 bubble at target price when price first reaches your profit-target level.
🔔 Alerts & Webhooks
- On-screen alert conditions “Mickey’s EMA → BUY” and “Mickey’s EMA → SELL” appear in the Create-Alert dialog.
- Dynamic JSON payload sent via alert() when a crossover fires, e.g.:
{
"script": "AAPL",
"scriptType": "equity",
"instrumentType": "NASDAQ",
"timeframe": "5",
"trend": "CE",
"price": 174.25
}
Use these alerts to integrate with bots, chat systems, manual, or any webhook-driven workflow.
🚀 Why Use Mickey’s EMA?
- Clarity & Precision: All signals appear exactly at the EMA or price-level of interest.
- Custom Risk Management: Define your own stop-loss and target percentages.
- Seamless Automation: Dynamic JSON alerts mean zero manual setup for webhooks.
- Versatile: Equally effective on intraday charts or daily/weekly timeframes.
Add Mickey’s EMA to your TradingView chart today and get instant, aesthetically-pleasing guidance on trend entries, risk exits, and profit targets—all in one elegant overlay.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。