So, here is the HGIMatrix (version 27L):
Select your time frame (can be CURRENT -- so it follows the chart time frame) and whether you want to look at the current candle or closed candle. You can change some cosmetic stuff as well -- you'll work it out.
Make sure you have the named HGI indicator in your \Indicators folder as well.
In a next version, I might differentiate between the buffer7 wavey symbol and buffer8 wavey symbol -- but for the moment I just follow what Elixe is doing on the HGI indicator.
Have fun!
Edit: You can now switch AlertsOn = true, to be alerted each time a new signal arrives. Be prepared to be annoyed by this thing, especially if UseClosedCandle = false, as in this case you will likely have a new signal every minute.
Also, you can display some legends to describe what each symbol means -- not that anyone needs that.
Edit2: Added NotificationsOn switch. You must have entered your MetaQuotes ID in the Notifications-tab of Options. Be ready to be blasted by your phone ...
Edit3: Added the ability to display the most recent signal, not just the one on the open or previous candle.
Edit4: Waves are now high or low, depending on the postion of the wave in HGI. The cell contents now scales with the cell width and height.
Edit5: Added 'selectable' Alerts, to allow the trader to which type of signals and/or waves he or she wishes to be alerted. New parameters:
AlertOnTrendChange :: Gives an alert if a new TREND signal was spotted
AlertOnRangeChange :: Gives an alert if a new RANGE signal was spotted
AlertOnRadChange :: Gives an alert if a new RAD signal was spotted
AlertOnWeakWave :: Gives an alert if a new WEAK Wave signal was spotted
AlertOnStrongWave :: Gives an alert if a new STRONG Wave signal was spotted.
The whole Alert and Notification mechanism can still be switched on/off with AlertsOn and NotificationsOn as before. Also, if AlertsOn is true, but none of the other 'AlertOn....' flags is true, you still won't get any alerts.
Edit6: Two small changes: The tile that was changed in the last refresh, turns dark red and there is now an external parameter for the SymbolFont (default: WingDings)
Edit7: A new parameter, ShowAsList, allows the information to be arranged vertically in a list.
Edit8: Made the fonts a little smaller as we got reports that some text was cut off. Also, locked the screen height with a new parameter (ScreenHeight: default 720), to by-pass the problem of getting all the rows on one line in the list form.
Edit9: I was advised by Elixe that for version 15.01, the iCustom call needs to be different. This has been updated in this version.
Edit10: Added the MTF version of HGIMatrix. Set the TimeFrames parameter to a comma-separated list of known timeframes, eg. 5,15,60,240.
Note: be sensible with your numbers. Having 28 pairs with 5 timeframes, 8 buffers and max lookback of 100 requires a maximum of 112,000 iCustom calls! This is done every minute ... You will find that at the start you get quite a few 'red' cells ... This is probably due to the HGI-indicator still trying to load some more data. This settles down after a while. Have fun and let me know how you go.
Edit11: There are some minor cosmetic changes as suggested by trendinator. There are now parameters to set the colour of the wave-symbols, as well as the background color of the changed cell. Also the wording of the Alerts() has been changed.
Edit12: New version of HGIMatrixMTF allows to change the background color of a symbol by clicking on the cell.
Edit13: Two minor updates: The cell selections now survive Empty4-restarts, timeframe changes and indi re-initializations. Also, I have made HGI 15.06 the default HGI indicator.
Edit14: Added colouring of cells depending if hurst agrees with HGI. You can switch this of by setting ShowHurst = false. Also, there is parameter for the hurst colour: ClrHurst (default: Dark Green).
Edit15: Bug fixed. The hurst-flag was not initialized on a refresh.
Edit16: Was never released.
Edit17: As requested by Tebis (Ernst), HGIMatrixMTF now indicates a Trend (as defined by the LWMA60 and LWMA240 on H4), by coloring the SYMBOL names, like so:
GREEN : if BID > LWMA60 and BID > LWMA240
RED : if ASK < LWMA60 and ASK < LWMA240
GOLD : if none of the two above conditions are true
It was suggested that this important information was still lacking on the HGIMatrixMTF screen. Mind you, we don't have much more space to display any more information. Also, as suggested by skinner36 HGIMatrixMTF will now include all symbols from your Market Watch panel, if the IncludeSymbols parameter is left blank.
Edit17L: Added the hgi_lib version of 17. In this version, you no longer need the HGI_v15.06.ex4 indicator (or any version for that matter) in your \Indicators folder. (Of course you can leave them there, they won't do any harm). However, you do need the hgi_lib.ex4 file (attached) in your \Libraries folder. Tommaso has granted me permission to publish this library with the 17L version. The library will cease to work beyond April 1st, 2015, like the indicator. After a certain time, you will get differences in signals between 17 and 17L, as signals obtained via the library are always the latest, updated signals. Signals obtained via the indicator stay the same except for bar 0.
Edit18 and 18L: If there is no signal (or wave), no number is displayed next to it either. Also, the message text for Alerts, Notifications and Emails for signals now contains the candle number (between brackets) where it occurred.
Edit19 and 19L: To combat the number of Alerts, two measures have been taken:
(1) There will be no Alerts on initialization (that includes switching timeframes, or changing a parameter)
(2) There is now an option to save alerts to a text file. AlertsToFile. By switching AlertsOn off, but AlertsToFile on, all alerts will be directed to a text file (<ExpertName>.txt) in the \Files area. A sound will be played to alert that something was saved to the file. You could monitor the contents to this file in another application -- eg. Notepad++ (as suggested by Radar)
In addition, alorente's request was added. There is a new parameter ShowOnlyHurst that, when switched on, limits the display to only signals that agree with the Hurst direction. You still get Alerts (if switched on) for changes related to non-Hurst agreeing signals. Note that if you switch ShowHurst off and ShowOnlyHurst on, you get nothing. That would be right, as you deserve to get nothing.
Edit 20 and 20L; Two minor code changes: Added the current time to the message in the alert file and fixed a bug, introduced by ShowOnlyHurst. For setting up Notepad++ to monitor your alert file see this post from BobbyT. For the linux affectionados, (like myself), a tail -f on the file is good enough.
Edit 21 and 21L: Added Chart Open functionality. If you click on an arrow, the chart for the particular symbol and timeframe is opened.
Edit 22 and 22L: Added TemplateName parameter. If you click on an arrow, it will open the corresponding chart with the selected template applied. Many thanks to Tommaso (milanese) for the code suggestion.
Edit 23 and 23L: Baluda has added the text that represents the time remaining of the current bar, for the selected timeframes. This text has been added underneath the 'H4', 'H1' 'M15' etc. column heads. Thanks Paul for this contribution. Also, I changed the scaling of font size with the selected CellHeight and CellWidth a little bit better, so that now (hopefully) the symbol and time frame text fits within each cell.
Edit 24 and 24L: Alerts can now be enabled by timeframe. Set the AlertOnXXX parameters to a comma-separated list of timeframes (like: "1440,240,60,15") for which you want to receive Alerts. Setting the parameter to "" (empty string), means: no Alerts on any timeframe. Also, make sure that the TimeFrames parameter contains the timeframe for which you have requested Alerts for.
Edit 25 and 25L: Symbols (arrows and waves) for bar=0 (the current bar) are now flashing to attract the attention, as per Alorente's request.
Edit 26 and 26L: You can now switch the flashing arrows on and off with the ShowFlash parameter.
Edit 27 and 27L: There is a new parameter, called AlertOnlyHurst, to specify that you only want to receive Alerts for signals/waves if the new signal/wave agrees with the Hurst-condition.
Edit 28 and 28L: Two tiny changes:
(1) Fixed a bug such that it now recognises the Monthly timeframe (43200).
(2) Split the Alerts for Waves into "Range Wave Above" and "Range Wave Below". Ie. the Alert now indicates if the wave is above or below the candle. This came as a suggestion from trendinator by PM.
Edit 29 and 29L: In this version the Arrows are smaller and the Waves are bigger on Alorente's request
Edit 30 and 30L: The symbol selection routine has been revamped. For that purpose, we have three parameters:
(1) IncludeSymbols: Leave it blank if you want to include all symbols in the market panel, or specify just the symbols you want. The string 'NULL' is translated to the symbol of the current chart.
(2) ExcludeSymbols: Leave it blank if you don't want to exclude any symbols, or specify the symbols you want to exclude. Again 'NULL' is translated to the symbol of the current chart.
(3) ExcludeExtensions: This is to specify, which symbol extensions you want to exclude. A symbol extension is defined as the string of characters that appears after the 6th character in the symbol name. Eg. in 'AUDUSD.', the extension is the '.' (dot) character.
The symbols you get are determined as follows:
If IncludeSymbols is empty: You will get all symbols in the market panel, minus those in ExcludeSymbols and minus those which have an extension in the ExcludeExtentions list.
If IncludeSymbols is non-empty: You will only get the symbols in IncludeSymbols, as long as they are listed in the market panel and as long as their extension is not in the ExcludeExtentions list.
Edit 31 and 31L: Two small changes:
(1) The ATR (Average True Range) value (in PIPs) is displayed below the symbol. The ATR is calculated for the given ATRTimeFrame and ATRPeriod. The display of this number can be switched on/off with the ShowATR parameter (default: true). There is also a ATRThreshold parameter (default: 100.0) and a ShowOnlyATR parameter (default: false). By setting ShowOnlyATR to true, the matrix will only list symbols that have an ATR of at least ATRThreshold.
(2) Due to popular demand, you can now also click on the 'Wave' symbol, to open up a chart for the given symbol and timeframe.
Edit 32 and 32L:
There was a change request to be able to switch-off signals you're not interested in. So, I have introduced three new parameters:
- ShowTrendSignal (default: true)
- ShowRangeSignal (default: true)
- ShowRadSignal (default: true)
Edit 33 and 33L:
There was a change request from dydynamic, to allow a timeframe specific MaxBarLookback setting. To this end, it is now possible to define the TimeFrames as a comma-separated string of tuples, like <timeframe>:<maxLookback>. So, eg. if you set TimeFrames to "240:10,60:30,15:100", the max bar lookback for H4 is 10, H1 is 30 and for M15 is 100. This is still backwards compatible with the previous format, as if you set TimeFrames to "240,60,15", each timeframe will have the default setting of MaxBarLookback.
Edit 34:
In this version the changes made by peteforex are included, most notably the addition of the ATR value in account currency. Thank you Pete, for these modifications! You are a ST*R.
In addition, I have merged the indicator version and the library version into one source file. The thinking is that most users will decide once and for all, whether to use the indicator version or the library version (with the majority choosing the library version). The code in the attached HGIMatrixMTFv34.mq4 (as it is) compiles to the library version. Those, who want to use the indicator version, will have to change line 16 from
Code: Select all
#define HGI_LIB
Code: Select all
//#define HGI_LIB
Edit 35:
I had a request from Petrocelli (Pete) to have the option to send alerts to an email account. No biggie. There is now a new parameter SendEmailOn (Default: false). If AlertsOn is set to true and SendEmailOn is also set to true, it should send alerts to your configured email account.
Any probs ... you know where to find me.