signalTable
Download scriptThis script serves as a comprehensive visual dashboard for traders, designed to provide a multi-timeframe overview of market conditions at a single glance. Instead of requiring you to switch between different charts manually, it aggregates technical data from nine different timeframes onto one screen.
Core Functionality
The tool creates a organized grid of signals. It monitors three distinct types of technical indicators across nine specific time periods (ranging from the 1-minute chart up to the monthly chart). These indicators are displayed using visual icons:
- Moving Average (MA): This measures the general trend direction. The script compares a short-term average against a longer-term average to determine if the momentum is bullish or bearish.
- Williams Percent Range (WPR): This is used to identify overbought or oversold conditions. The dashboard will signal when the price has moved into an extreme zone or remains in a neutral "no signal" state.
- Parabolic SAR: This indicator identifies potential trend reversals. The script tracks whether the current price is above or below the "dots," providing a clear visual of the prevailing trend direction.
User Experience and Visuals
The logic is designed for high readability and clarity:
- Multi-Timeframe Matrix: The dashboard automatically calculates data for 1M, 5M, 15M, 30M, H1, H4, D1, W1, and MN1 periods simultaneously.
- Color-Coded Alerts: To make decision-making faster, the script uses a specific color system:
- Gold typically represents "Buy" signals or bullish momentum.
- Medium Purple represents "Sell" signals or bearish momentum.
- White Smoke indicates a neutral state (no clear signal).
- Dynamic Updates: The script constantly refreshes these icons in real-time, ensuring that as the market moves, your dashboard updates instantly to reflect the current status of all timeframes.
- Automatic Cleanup: The tool is designed to be "clean." When you remove the indicator from your chart, it automatically deletes all the labels and objects it created, leaving your workspace tidy.
Summary for the Trader
Essentially, this tool acts as a "command center." It allows you to see if the market is aligned across different timeframes—for example, checking if the 1-hour and Daily trends are both pointing in the same direction before making a trade. By consolidating these three key indicators into one visual grid, it simplifies complex market analysis into a quick, color-coded summary.
//////////////////////////////////////////////////////////////////////
//
// signalTable.mq4
// Antonuk Oleg
// antonukoleg@gmail.com
//
//////////////////////////////////////////////////////////////////////
#property copyright "Antonuk Oleg"
#property link "antonukoleg@gmail.com"
#property indicator_chart_window
extern int scaleX=20,
scaleY=20,
offsetX=35,
offsetY=20,
fontSize=20,
corner=2,
symbolCodeBuy=67,
symbolCodeSell=68,
symbolCodeNoSignal=73;
extern color signalBuyColor=Gold,
signalSellColor=MediumPurple,
noSignalColor=WhiteSmoke,
textColor=Gold;
int period[]={1,5,15,30,60,240,1440,10080,43200};
string periodString[]={"M1","M5","M15","M30","H1","H4","D1","W1","MN1"},
// ñîçäàåì åùå îäèí ìàññèâ ñ íàçâàíèÿìè èíäèêàòîðîâ
signalNameString[]={"MA","WPR","SAR"};
//////////////////////////////////////////////////////////////////////
//
// init()
//
//////////////////////////////////////////////////////////////////////
int init()
{
// òàáëèöà ñèãíàëîâ
for(int x=0;x<9;x++)
for(int y=0;y<3;y++)
{
ObjectCreate("signal"+x+y,OBJ_LABEL,0,0,0,0,0);
// èçìåíÿåì óãîë ïðèâÿçêè
ObjectSet("signal"+x+y,OBJPROP_CORNER,corner);
ObjectSet("signal"+x+y,OBJPROP_XDISTANCE,x*scaleX+offsetX);
ObjectSet("signal"+x+y,OBJPROP_YDISTANCE,y*scaleY+20);
ObjectSetText("signal"+x+y,CharToStr(symbolCodeNoSignal),
fontSize,"Wingdings",noSignalColor);
}
// íàçâàíèÿ òàéìôðåéìîâ
for(x=0;x<9;x++)
{
ObjectCreate("textPeriod"+x,OBJ_LABEL,0,0,0,0,0);
// èçìåíÿåì óãîë ïðèâÿçêè
ObjectSet("textPeriod"+x,OBJPROP_CORNER,corner);
ObjectSet("textPeriod"+x,OBJPROP_XDISTANCE,x*scaleX+offsetX);
ObjectSet("textPeriod"+x,OBJPROP_YDISTANCE,offsetY-10);
ObjectSetText("textPeriod"+x,periodString[x],8,"Tahoma",textColor);
}
// íàçâàíèÿ èíäèêàòîðîâ
for(y=0;y<3;y++)
{
ObjectCreate("textSignal"+y,OBJ_LABEL,0,0,0,0,0);
// èçìåíÿåì óãîë ïðèâÿçêè
ObjectSet("textSignal"+y,OBJPROP_CORNER,corner);
ObjectSet("textSignal"+y,OBJPROP_XDISTANCE,offsetX-25);
ObjectSet("textSignal"+y,OBJPROP_YDISTANCE,y*(scaleY)+offsetY+8);
ObjectSetText("textSignal"+y,signalNameString[y],8,"Tahoma",textColor);
}
return(0);
}
int start()
{
for(int x=0;x<9;x++)
{
// ñèãíàë íà ïîêóïêó
if(iMA(Symbol(),period[x],13,0,0,0,0)>iMA(Symbol(),period[x],24,0,0,0,0))
ObjectSetText("signal"+x+"0",CharToStr(symbolCodeBuy),fontSize,"Wingdings",signalBuyColor);
// ñèãíàë íà ïðîäàæó
else
ObjectSetText("signal"+x+"0",CharToStr(symbolCodeSell),fontSize,"Wingdings",signalSellColor);
}
for(x=0;x<9;x++)
{
// ñèãíàë íà ïîêóïêó
if(MathAbs(iWPR(Symbol(),period[x],13,0))<20.0)
ObjectSetText("signal"+x+"1",CharToStr(symbolCodeBuy),fontSize,"Wingdings",signalBuyColor);
// ñèãíàë íà ïðîäàæó
else if(MathAbs(iWPR(Symbol(),period[x],13,0))>80.0)
ObjectSetText("signal"+x+"1",CharToStr(symbolCodeSell),fontSize,"Wingdings",signalSellColor);
// íåò ñèãíàëà
else
ObjectSetText("signal"+x+"1",CharToStr(symbolCodeNoSignal),fontSize,"Wingdings",noSignalColor);
}
for(x=0;x<9;x++)
{
// ñèãíàë íà ïîêóïêó
if(iSAR(Symbol(),period[x],0.02,0.2,0)<Close[0])
ObjectSetText("signal"+x+"2",CharToStr(symbolCodeBuy),fontSize,"Wingdings",signalBuyColor);
// ñèãíàë íà ïðîäàæó
else
ObjectSetText("signal"+x+"2",CharToStr(symbolCodeSell),fontSize,"Wingdings",signalSellColor);
}
return(0);
}
//////////////////////////////////////////////////////////////////////
//
// deinit()
//
//////////////////////////////////////////////////////////////////////
int deinit()
{
// ïðè óäàëåíèè íàøåãî èíäèêàòîðà íóæíî óäàëèòü âñå îáúåêòû,
// êîòîðûå ìû óæå ñîçäàëè
ObjectsDeleteAll();
return(0);
}
Comments