- The Basics
- Comparing Outputs
- The Data Tab
- Adding Data
- Modifying Data
- Deleting Data
- The Signals Tab
- Data ? Data
- Data (Arrow)
- Data (Signal)
- Reversing a Signal
- The Display Tab
- The Options Tab
- Showing/Hiding Signals
- Locking Data to a Specific Timeframe
- Using Complex Data
- Custom Dashboard Label
The Universal Signal Dashboard (USD) is a signal dashboard or indicator matrix. It can generate a matrix of signals from values, chart and candle prices, and from the output of almost any technical indicator. However, unlike most dashboards of the same category, USD is configurable based on the input provided by the user.
Full Version Versus Demo Version
|Feature||Subcategory ||Universal Signal Dashboard Demo || Universal Signal Dashboard|
| Raw values||YES||YES|
| Bid & ask prices||YES||YES|
| Candle prices||YES||YES|
| Standard indicators||YES||YES|
| Custom indicators||YES||YES|
| Combination of data entries (Complex type)||NO||YES|
| Comparison of two data||YES||YES|
| Indicator Arrow||YES||YES|
| Combination of signal entries (Complex type)||NO||YES|
| Push Notification||NO||YES|
| Saving and Loading (Files)||NO||YES|
| Locking Data to Specific Timeframe||YES||YES|
| Locking Data to Specific Symbol ||YES||YES|
| Global Timeframe ||YES||YES|
| Global Symbol ||YES||YES|
| Show/Hide Display Entries ||YES||YES|
| Automated Updating of Signals||YES||YES|
The BasicsUpon loading the dashboard on a chart, the user would be able to see the following tabs:
- Data Tab – used for defining the data which will be used by the dashboard
- Signals Tab – used in generating signals based on the data available
- Options Tab – used for saving and loading, and setting global symbol and timeframe
- Display Tab – the actual display for the signals
Using the app basically involves the following steps:
- First, think of a signal based on some factors (e.g. chart prices, candle prices, indicator, etc.)
- Then, define the data that signal will need by creating data entries (under the Data tab)
- Next, define the signal itself by creating a signal entry (under the Signal tab)
- View the dashboard or matrix generated from the signal (under the Display Tab)
The Display tab is the tab where the actual signals can be viewed. This tab starts empty and the user will have to configure the data and signals first before anything can be displayed.
Each signal entry is evaluated for each of the standard timeframes:
- M1 (1 minute)
- M5 (5 minutes)
- M15 (15 minutes)
- M30 (30 minutes)
- H1 (1 hour)
- H4 (4 hours)
- D1 (1 day)
- W1 (1 week)
- MN1 (1 month)
- Gray – no signal
- Lime – long signal
- Red – short signal
- Yellow – presence of long and short signals
Comparing OutputsComparison of output values is used extensively throughout the dashboard. Therefore, the user should be knowledgeable on how software compares values in order for the dashboard in order for it to be useful. When comparing values, a software will need 3 parameters:
- Lvalue, or value on the left-hand side of the equation
- Rvalue, or value on the right-hand side of the equation
- An operator – the following operators are used:
- Equal (==)
- Greater than (>)
- Greater than or equal (>=)
- Less than (<)
- Less than or equal (<=)
- Not equal (!=)
- Arithmetic operators (+, -, *, /)
The use of arithmetic operators is common knowledge, so we turn our focus to comparison operators.The dashboard uses equations of equality/inequality in order to check if there is a signal or not. If an equation or statement is true or correct, then there is a signal. If the statement is false, then there is no signal. This is evaluated separately for long and short signals. Consider the following comparison:
MA200 > MA100
Based on the above comparison, we are comparing the the value of a 200-period moving average against the value of a 100-period moving average. The lvalue in this case is the value representing MA200, while the rvalue is the value representing MA100. The operator is > (greater than).Let us assume that the value representing MA200 in the example is 1.0000 and that of MA100 is 2.0000. The equation is then translated into the following:
1.0000 > 2.0000
1 is always less than 2, so the equation returns false. Normally, MA200 > MA100 is used in checking for a sell signal, as MA200 will lag more than MA100. If this criteria is used in an actual sell signal, the result would be a “no sell signal” since the result is false.On the other hand, consider the following comparison:
MA200 < MA100
1.0000 < 2.0000
The above comparison will return true, since 1 is always less than 2. If this comparison is used in checking for a buy signal, then there will be a signal to buy since the statement of the comparison is correct or true.
As stated earlier, a sell signal will result to a red box in the display, while a lime box will come from a buy signal. If both signals evaluated to false, then there is no signal, and this will result to a gray box. Meanwhile, a yellow box is the result when the evaluation of both buy and sell signals returns true.
The Data TabBefore evaluating any signals, the data that the signal will used must be declared first. The following types of data can be defined within the dashboard:
- Chart Price (Bid and Ask)
- Candle Price (Open, High, Low, Close, Median, Typical, and Weighted Prices)
- Standard Indicators
- Custom Indicators
- Complex Data
The Data tab has the following buttons to manage data entries:
- Add – used for adding data entries
- Modify – used for modifying existing data entries
- Delete – used for deleting existing data entries
To add a new entry, simply click on the “Add” button on the right hand side of the tab.
To modify an existing entry, simply click on the “Modify” button on the right hand side of the tab. The settings for the data can be seen in a sub-dialog.
Upon clicking the modify button, the sub-dialog will appear.
The first thing to do is to specify the type of data to use (“Type”). Each type of data is discussed in the following sub-sections.
Each entry also has a name parameter (“Name”). Assigning a short, meaningful name is highly recommended, as this makes each data entry easy to work with.
The Symbol is used in all types except Value and Complex. The default is “Use Global”, which will use the assigned value on the Options tab.
The Timeframe is used in all types except Value, PRICE_ASK, PRICE_BID and Complex. The default is “Use Global”, which will use the assigned value on the Options tab. If a specific timeframe is used, the value derived on that timeframe will be used on all other timeframes when evaluating signals.
- Value - The Value is the simplest type of data. It only stores a fixed value. The value can only be numbers – integers (e.g. 1, 2, 3, -1, -2, -3, etc.) and doubles (e.g. 3.1416).
- Chart Price - The Chart Prices are available as PRICE_BID and PRICE_ASK. It requires a symbol (e.g. EURUSD).
- Candle Price - The candle prices require both a symbol and a timeframe.
- Indicators - Most of the choices on the Type field are indicators. These are the standard indicators that are available in Metatrader.
- Complex data (more on this later)
When using custom indicators, one should select IND_CUSTOM in the Type field, and specify the name of the indicator on the field named “IND Name”, without the extension. Once the custom indicator is found, its parameters will be automatically displayed, if there are any. On the other hand, if the custom indicator is not found, the field will be cleared and no indicator will be loaded until a valid indicator name is specified.
For example, the Zigzag indicator is a custom indicator. It comes with a fresh installation of Metatrader, and can be found at "Examples\ZigZag" under the Navigator window. To be able to declare a data using this indicator. One should enter the location of the indicator, and add another "\" character for every "\" character. For example, "Examples\ZigZag" becomes "Examples\\ZigZag" (without the quotes):
The user will know if the indicator has been found. The "IND Name" field will retain the name, and the parameters will be loaded, if there are any, just like in the screen shot above. The Zigzag indicator has three parameters, and that is loaded as well, as shown above. If it is not found, no parameters will be displayed, and the "IND Name" field will be reset.
When getting data from custom indicators, it is important to know beforehand which buffer controls which indicator output. This will make it easier to target a buffer when working on the signal entry based on the indicator.
To delete an existing entry, simply click on the “Delete” button on the right hand side of the tab.
The Signals Tab
When working with signals, there are three possible types available on the dashboard:
- Data ? Data – comparison of data
- Data (Arrow) – detection of indicator arrows
- Data (Signal) – combination of one or more signals
The signals dialog allocates separate settings for long and short signals, which allows for greater customization.
Index and Buffer
Some data types require an index and a buffer in order to retrieve a value. Candle prices and indicators require an index. On the other hand indicators can have one or more buffers, depending on the number of their outputs (lines or objects drawn on the chart).
Indicators and candle prices give different values at different points in time. In order to get a value from an indicator, one needs to specify an index representing a point in time on the chart. The indices are labeled in reverse order (time-series). An index of zero refers to the unformed bar, an index of 1 refers to the last formed bar, an index of 2 refers to the bar that formed 2 bars ago, and so on. For example, when one needs to get the value of an indicator with an index of 1, it means that he wants to get the value of the indicator 1 bar ago.
The indices update at the formation of each new candle, so the unformed bar will always have an index of 0, the last formed bar will always have an index of 1, and so on.
Most indicators only have a single buffer. An example of this is the moving average. It only outputs one line. The single, continuous line is one artifact, and so the indicator needed only one buffer. Indicators such as MACD, on the other hand, paints two artifacts on the chart (the main MACD line and the signal line), and so it has two buffers. One good way to see the buffers of an indicator and their values is through the data window in Metatrader.
Like the index, buffers starts with 0. Thus, the first buffer will always have an index of 0, the second buffer will have 1, and so on.
Data ? Data
Data ? Data deals with the comparison of two values represented by the data entries defined under the Data tab. The “?” sign denotes the operator to be used in the comparison, which the user should specify.
The user should specify the lvalues, rvalues, and the operator, as well as the buffers and indices, whenever applicable.
Example #1: Accelerator/DeceleratorThe accelerator oscillator is often used to detect early changes in market momentum. The signals generated from this indicator usually involves a comparison with a fixed value, such as the following:
- If AC is greater than the fixed value, the signal is long
- If AC is less than the fixed value, the signal is short
For this example, we need two distinct data: the AC indicator, and the fixed value. The fixed value is usually zero, which we will use for this example.
First, we need to define the AC indicator. Under the data tab, click on the “Add” button, highlight the new item created on the list, and then click the “Modify” button. The fields should be filled out as shown on the following figure:
In the above screen shot, the data entry has an alias “ac”.
Next, we need to define a data entry for the fixed value. Perform the same method above, but assign VALUE type, similar to the following figure:
Navigate to the Signals tab, and click on the “Add” button to create a new signal. Assign a name of “AC” under the General tab of the sub-dialog (this is optional).
Under the Long tab of the sub-dialog, assign the data “ac” as the lvalue, and “zero” as the rvalue.
Since this is for checking a long signal, we would like to check if the AC indicator is greater than zero, so we used the greater than sign (“>”) as the operator.
Here, we used a buffer of zero and an index of 1. The AC indicator (when viewed under the data window) only has a single buffer, and so a buffer of 0 is the only option for buffer value for this indicator. On the other hand, we used an index of 1, which refers to the value of the AC indicator at the last formed bar.
Do the same for the short signal (on the Short tab of the sub-dialog), but this time with a different operator.
Since this is for checking a short signal, we would like to check if the AC indicator is less than zero, so we used the less than sign (“<”) as the operator.
In order to see the generated signal, go to the Display tab:
Example #2: Bullish/Bearish Candle
In this second example, we would like to see if the last candle closed bearish or bullish on each of the standard timeframes. In order to determine this, we would require two types of data:
- The open price of the candle
- The closing price of the candle
If the open price is less than the closing price, then we have a bullish bar. On the other hand, when the open price is greater than the closing price, we have a bearish bar.
For the data for the candle open price, we create a new data with the following settings:
For the data for the candle close price, we create a new data with the following settings:
We then go to the signals tab. For the long signal:
Candle prices do not have buffers, since they are not indicators. We can notice that the buffer field is hidden in this case. The data are stored as time-series, however, so it still requires the index field.
For the short signal:
The signal entry can then be seen from the Display tab:
Example #3: Two Moving Averages
In this example, we will compare two moving averages with periods 100 and 200, respectively. If MA200 is greater than MA100, then we have a sell signal. On the other hand, if MA200 is less than MA100, we have a sell signal.
First we declare the data. The sub-dialog for MA100 is shown in the following figure:
Note that you will need to specify the period to 100, available on the list of parameters at the bottom of the sub-dialog.
The data entry for the ma200 is shown in the following figure, which does not differ much from the ma100 data entry.
For the signal entry, for the long signal, MA200 should be less than MA100, as shown in the following figure:
The opposite is true for the short signal:
To view the signal on the dashboard, navigate to the Display tab:
Example #4: MACD
MACD is based on moving averages. But unlike MA, MACD has two buffers instead of just one: the main line and the signal line. In this example, we will configure it so that the MACD will output a buy signal when the signal line is below the main line (histogram), and a sell signal when the signal line is above the main line histogram.
In this example, we would need just one type of data, which is the MACD indicator itself. We then make the comparison from its buffers alone. The following shows the data entry:
Now, setting up the signal entry is a little different, because we will have to use other buffer values aside from zero. The process gets more complicated the more buffers an indicator has.
For the MACD standard indicator, the main line is assigned as the first buffer, while the signal line is assigned as the second buffer. Thus, the main line will have a buffer of 0, while the signal line will have a buffer of 1.
For a long signal, the main line should be less than the signal line. One way to set this up is to set the lvalue buffer value to zero (which is also the default), and the rvalue to have a buffer value of 1 (the signal line). We then use the less than operator (“<”) to compare the two:
We also do the same for the short signal, but this time reversing the operator, from “<” to “>”:
Like in the previous examples, we view the signal by going to the Display tab:
Indicators that output arrows or symbols on the chart are treated separately. These indicators, rather than having a continuous line or histogram as its output, only paints symbols and arrows at select points on the chart. Depending on the indicator, it can display more than one type of symbol or arrow on the chart, usually based on the number of its data buffers.
A good example of this type of indicator is the Fractals indicator. This indicator has two output buffers. One is for the up arrow, placed at the high price of the candle alongside it. The other is for the down arrow, which is placed at the low price of the candle alongside it:
Each buffer of such indicators normally have either of the two categories of values:
- A very large number or empty value
- A value in terms of chart price.
When a buffer does not display any value, or displays a very large number that is off the charts (equal to DBL_MAX or EMPTY_VALUE), no arrow is painted for that buffer on the indicated time on the chart. On the other hand, when one sees a valid chart price representing a certain buffer value, an arrow can be seen from the indicated time on the chart.
Lvalue FieldUnlike Data ? Data, Data (Arrow) only accepts an lvalue. It does not have fields for rvalue and the operator.
The index behaves differently for this type of signal. For example, if the index is assigned a value of 10, the signal will look at the last 10 historical bars for any presence of an indicator arrow. If looking for a buy signal, the signal will look for a buy arrow (defined by buffer index) in any of the 10 previous bars. The same is true when checking for sell signals.
This is unlike the previous signal type, such as, when we assign an index of 10, the signal will use for the value of the indicator 10 bars ago. In Data (Arrow) a presence of the target arrow in any of the 10 previous bars will result to having an output of a buy signal.
If Both Long and Short Signals Are Present
If both signals are present, then the signal will output the latest signal detected. For example, if the index is set to 10, and a buy arrow appeared on index 10, while a sell arrow appear on index 5, then the final output will be a sell signal. The buy arrow appeared earlier than the sell arrow, so the sell arrow is the most recent signal.
If both long and short signals are present on the same index or bar, then the output will be both long and short, resulting to a yellow box on the dashboard.
Example #5: Fractals
In order for a Fractal to appear certain conditions must be met. For an up arrow, the high of the candle where the arrow is placed should be higher than the highs of the two candles before and after it. For a down arrow, the opposite is true. The low of the candle where the arrow is placed should be lower than the lows of the two candles before and after it. This means that a fractal arrow will arrive much later, since it still need time to confirm if the next two bars into the future will have lower highs or higher lows. The earliest permanent arrow will appear from 3 bars ago. It is possible for one to appear in as early as two bars ago, but that arrow may disappear due to repainting.
To construct a signal based on Fractals, first we need to declare the data. We only need one type of data, which is the indicator itself:
We then create a signal entry. For this signal, we need to scan the previous 10 historical bars. We would only search for arrows that are permanent (will not delete later), so we will start the scan from 3 bars ago. This means that the signal will search the 3rd, 4th, 5th, 6th, 7th, 8th,9th, and 10th historical bar (starting from the current bar, which has index 0) for the presence of any arrows.
For the long signal. We assign the value of 1 as buffer, which is the buffer for the down arrow. We give the “From” field a value of 3, which is the starting index to search, and an index of 10, which is the maximum index to search:
We also do the same for the short signal, but use a buffer of 0:
Like in the previous examples, we view the signal by going to the Display tab:
Data (Signal)Data (Signal) combines one or more of other signals defined in the dashboard.
Example #6: Fractals + Accelerator
In this example, we will combine the signals from the Accelerator and Fractals indicators which were constructed in previous examples. First, we define the data and signal entries for the two indicators. Then, under the signals tab of the sub-dialog, for the long signal, we add the entries from the left side of the selection list, to the selection list on the right hand side:
We also do the same for the short signal (unless we want a different combination of signals):
When viewed from the display, the result can be found on the third row:
In the above configuration, we used the "AND" operator. This means that all component signals should agree on the same direction.
For M1, M5, and W1, both AC and Fractals gave the same direction, red (short). Thus, the final output is red (short). The same is true for M5, but in this timeframe, the final output is green (long).
For H4, the two signals do not agree on the same direction, so the final output is gray (no signal).
For M30, only one signal (AC) gives a red signal (short), but the other signal (Fractal) returned none. Since we used the "AND" operator, all component signals should agree. Thus, the final output is gray (no signal). The same is true for MN1, whose AC signal has a long output instead.
H1 is a special case. AC is green. However, Fractals is yellow, which means that there is signal from both sides for this indicator. The two indicators do not agree on a short direction, since one is green, but they both agree on the long direction. Thus, the final output is green.
Reversing a Signal
With Data (Signal), it is possible to reverse the output of a single signal, or a set of other signals. A long signal becomes a short signal and vice versa. In Example #6, we can reverse the signal through the “Reverse” field of the long and short tabs of the signal sub-dialog. The following signal shows another entry with the third signal on the list reversed:
Entry #3 is the same as #4, except that #4 has the reverse field set to True. This causes it to return the opposite of the outputs of #3. Note that gray colors (no signal) remain unaffected by this change.
Notice that on the signal entry for Example #6, we assign the value of “AND” on the Mode field. This mode means that all the signals added to the list should agree on the same signal. If all agree to the same signal, the final output would be the color of all the indicated signals. If not, then there would be no signal, and the output would be gray.
If we switch the mode to “OR” instead, it would return the combination of all the signals. For example, if one signal gives red and the other gives green, then the combined signal would be yellow. If all gives the same color, then the final output would also be that color. Before we show the signal entry using "OR", let us show first how the dashboard looks like before the changes:
The third signal uses the AND operator, so if the first two signals do not agree, the result is a gray (no signal).
To do the OR signal, we can either modify the existing signal entry (third signal) or create a new one. For this example, we will create a new signal entry:
Notice that the "Mode" field now uses "OR" instead of "AND". We also do the same for the short signal:
The new display would look like the following:
For the M1 timeframe, the AC signal is green (long), while the Fractals returns gray (no signal). The final output is red.The same is true for M30 (long signal), and for MN1.
For the M15 timeframe, the two signals agree on the same direction, so the final output is green, similar to the "AND" mode.
For H4, D1, and W1, each of the two signals do not agree on the same signal. But since this is a combination, the components do not have to agree, they just need to "add up" leading to the final signal. The final output is therefore yellow (both long and short signal).
For H1, we have a special case. AC outputs green, but Fractals outputs yellow (both green and red). Here, we can see the presence of both long and short signals: One signal outputting green (AC), and one signal outputting both green and red (Fractals). Thus, the final output using the "OR" mode is yellow.
The Display Tab
The Display tab has already been discussed in earlier sections. Although there are a few points worth remembering about this tab:
- The display tab updates approx. once every 5 seconds.
- The actual signal objects are created as soon as the user navigates to this tab. Thus, if the user made some changes to any of the data or signal entries, he should switch to this tab right after in order for the changes to actually take effect.
The Options Tab
Saving and Loading
It is possible to save and load individual dashboards on separate files. Fields are provided for saving and loading. When loading a file, one simply needs to select from a list of files detected in the data folder. The actual files can be found under <data folder>\<MQL4 or MQL5>\Files.
Global Symbol and Global Timeframe
By default, each data entry uses the global setting for symbol and timeframe. Changing the global symbol and/or timeframe allows one to change these values without having to spend too much time in reconfiguration. For example, if a user has a dashboard with a global symbol of EURUSD and he would like to see how the same dashboard will look like for GBPUSD, all he needs to do is to change the global symbol to GBPUSD. With this, all the other entries that uses global symbol will also use GBPUSD.
Signal entries can be shown/hidden from the Display tab. This is done through the “Show” field, which can be found on the General tab of the signal sub-dialog. This can be useful when combining signals and the user only needs to see the final signals, and not their component signals. For example, consider the following dashboard:
On the above screen shot, we can see four entries. Entries #3 and #4 are based on entries #1 and #2. Now, we want to minimize clutter, because we only wanted #3 and #4 for trading. We would like to hide entries #1 and #2 and show only #3 and #4.
To do this, we use the show parameter of the signal entry. We set it to false. The following shows the setting for the AC signal:
Note that in this setting, the "Show" field is now set to false. We also do the same for the Fractals signal:
With the two signal entries hidden, we can then expect only two entries to be visible on the display of the dashboard:
The above screen shot is the same as the first screen shot in this section, only that the AC and Fractals entries are now hidden.
Locking Data to a Specific Timeframe
When comparing data, what we see so far is that we can only compare data from the same timeframe. For example, when the symbol is EURUSD and the timeframe is PERIOD_D1, and we would like to compare the open and close prices to check for a bullish/bearish bar, we can only use the open and close prices of the daily chart in this scenario.
This problem can be circumvented by applying a specific timeframe to a data. The default timeframe is “All Timeframes”. If we choose a specific timeframe, then that timeframe will be consistently used when getting the value of the data, from M1 to MN1.
Let us revisit Example #2. This is a dashboard that checks whether the last formed bar closed bearish or bullish for each of the standard timeframes:
Here, we only compare the M1 open price with the M1 close price, the M5 open price with the M5 close price, and so on. There are cases where a comparison of data coming from different timeframes will be needed. An example of this is to compare the last close price of each standard timeframe with the current open price of the D1 timeframe. We need to declare another data entry, whose timeframe is locked to the D1 timeframe:
Then we move on to declaring the signal entry. For long tab of the subdialog is shown in the following figure:
Notice that we assigned an index of 0 for the open price data for d1. We would like to compare the current open price, or the open price of the unformed bar on the D1 chart.
We also do the same for the short signal:
We can see the two signals at the Display tab as shown below:
At this particular instance on the chart, all last bar closing prices on the standard timeframes except MN1 are above the current open price of the D1 candle.
Using Complex Data
Complex data is one way to combine the values of two data entries into a single entry. The process makes use of an arithmetic operation between two values. Some examples where this might be used are the following:
- Creating an offset value for a moving average indicator
- Getting the typical, median price, and weighted prices (although these are already provided as separate data types)
- Getting the average of two or more indicator outputs (this require at least two complex data, one for addition, and one for division)
Custom Dashboard Label
There is also an option to change the label on the main dashboard. This makes it easier to remember and identify dashboards especially if multiple instances are being used in the platform. Under the expert properties, there is a parameter named “appname”. Enter your preferred name for the dashboard under this field and the dashboard will use that as its label (caption). On the following screen shot, we specify a custom name under the expert properties window ("EURUSD").
The resulting dialog window with caption is shown below, as we can see, it now uses the custom name we specify:
Alerts can be found under the General tab of the signal sub-window, as shown in the following figure. Each individual signal can be configured to send popup alerts, email alerts, and push notifications. To activate an alert, simply click on the designated buttons on the alert matrix. This is configured on a per-signal basis. The following shows the configuration of popup alerts on the AC signal:
The alerts only trigger on change of signal, such as alert shown in the following screen shot:
Hidden signals are still capable of sending alerts despite not being shown on the Display tab.
The autosave feature allows one to preserve the current state of the dashboard when switching charts (symbol or timeframe) and accounts.
To activate this, simply specify a filename on the autosave file input found on the expert properties window.
The default is to use "autosave.dash" as the autosave file. However, if using multiple dashboards, it is recommended to use different autosave files for each of them, especially if the dashboards were configured differently.