FDM Entry Arrows with Alerts
Download scriptThis tool is designed to function as a visual signaling system for traders, providing real-time alerts and markers on your trading charts based on specific price movement patterns. Here is a breakdown of how the logic works:
Core Monitoring Logic The script constantly monitors the market by comparing two different types of moving averages (which are essentially smoothed versions of price history). It looks at these averages across two different timeframes: a "fast" setting to capture immediate momentum and a "slow" setting to identify the broader trend.
By comparing where the fast average is currently positioned relative to the slow average—and how those positions have shifted over the preceding and following bars—the script identifies specific moments of crossover or divergence.
Buy and Sell Signals The tool triggers signals based on the interaction between these moving averages:
- Buy Signals (Lime Markers): When the logic detects that the fast moving average has crossed above the slow moving average in a specific sequence, it identifies a potential upward momentum. The script then places a lime-colored arrow below the current price candle.
- Sell Signals (Red Markers): Conversely, when the fast moving average drops below the slow moving average following a specific downward shift, the script identifies potential bearish momentum. It places a red-colored arrow above the price candle.
Dynamic Distance Adjustment To ensure that the visual markers (arrows) do not clutter the candles or overlap with the price action, the script calculates the "volatility" of the recent price range. It uses this calculation to automatically space the arrows at a consistent distance away from the High and Low of the candle, ensuring clear visibility regardless of how volatile the market is at that moment.
Alert System Beyond the visual markers on the chart, the script includes an active notification system. When a new Buy or Sell condition is met in real-time, the tool generates a pop-up alert on your trading platform. This allows you to stay informed of potential opportunities instantly without having to constantly watch every price movement manually.
Trial Period Security The script contains a built-in expiration check. It verifies the current date against a specific deadline; if the current date exceeds this limit, the tool will notify the user that the trial period has ended and provide instructions on how to contact support for a full version.
/*
*/
#property copyright "Copyright © 2008, Forex Day Monster"
#property link "http://www.forexprofitmonster.com"
#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 Lime
#property indicator_color2 Red
double g_ibuf_76[];
double g_ibuf_80[];
int g_period_84 = 3;
int g_period_88 = 21;
extern bool Alerts = TRUE;
int gi_96 = 0;
int gi_100 = 0;
int init() {
SetIndexStyle(0, DRAW_ARROW, EMPTY);
SetIndexArrow(0, 233);
SetIndexBuffer(0, g_ibuf_76);
SetIndexStyle(1, DRAW_ARROW, EMPTY);
SetIndexArrow(1, 234);
SetIndexBuffer(1, g_ibuf_80);
return (0);
}
int deinit() {
return (0);
}
int start() {
int li_20;
double l_ima_24;
double l_ima_32;
double l_ima_40;
double l_ima_48;
double l_ima_56;
double l_ima_64;
double ld_72;
double ld_80;
string ls_0 = "2015.11.01";
int l_str2time_8 = StrToTime(ls_0);
if (TimeCurrent() >= l_str2time_8) {
Alert(" Trial version has expired! Email support@forexprofitmonster.com with broker account number for rights to full version!");
return (0);
}
int li_88 = IndicatorCounted();
if (li_88 < 0) return (-1);
if (li_88 > 0) li_88--;
int li_12 = Bars - li_88;
for (int li_16 = 0; li_16 <= li_12; li_16++) {
li_20 = li_16;
ld_72 = 0;
ld_80 = 0;
for (li_20 = li_16; li_20 <= li_16 + 9; li_20++) ld_80 += MathAbs(High[li_20] - Low[li_20]);
ld_72 = ld_80 / 10.0;
l_ima_24 = iMA(NULL, 0, g_period_84, 0, MODE_EMA, PRICE_CLOSE, li_16);
l_ima_40 = iMA(NULL, 0, g_period_84, 0, MODE_EMA, PRICE_CLOSE, li_16 + 1);
l_ima_56 = iMA(NULL, 0, g_period_84, 0, MODE_EMA, PRICE_CLOSE, li_16 - 1);
l_ima_32 = iMA(NULL, 0, g_period_88, 0, MODE_EMA, PRICE_CLOSE, li_16);
l_ima_48 = iMA(NULL, 0, g_period_88, 0, MODE_EMA, PRICE_CLOSE, li_16 + 1);
l_ima_64 = iMA(NULL, 0, g_period_88, 0, MODE_EMA, PRICE_CLOSE, li_16 - 1);
if (l_ima_24 > l_ima_32 && l_ima_40 < l_ima_48 && l_ima_56 > l_ima_64) {
g_ibuf_76[li_16] = Low[li_16] - ld_72 / 2.0;
if (li_16 <= 2 && Alerts && !gi_96) {
Alert(Symbol(), " ", Period(), " Day Monster BUY Alert ");
gi_96 = TRUE;
gi_100 = FALSE;
}
} else {
if (l_ima_24 < l_ima_32 && l_ima_40 > l_ima_48 && l_ima_56 < l_ima_64) {
g_ibuf_80[li_16] = High[li_16] + ld_72 / 2.0;
if (li_16 <= 2 && Alerts && !gi_100) {
Alert(Symbol(), " ", Period(), " Day Monster SELL Alert ");
gi_100 = TRUE;
gi_96 = FALSE;
}
}
}
}
return (0);
}
Comments