Half-discretion EA ELDRA How to trade with your favorite indicator (MT5 version)
Hello, I am Hoso no P, the author of ELDRA.
“When the indicator arrows I usually look at appear, I want them to enter automatically,” “I’ll handle the entry myself, so please let the indicator handle only the exit.” We often hear these kinds of requests.
ELDRA has a feature that allows you to use your own custom indicators as trading signals as-is. The settings are in 37–40. Since I wrote a previous article using RSI for the MT4 version, this time we’ll focus onthings unique to the MT5 versionandhow to use chart objects/arrows as signalsas the main topics.
Overview: four groups and their roles
| Number | Group | Role |
|---|---|---|
| 37 | Indicator Entry Settings | Which indicator, which bar, which buffer to read from |
| 38 | Indicator Parameter Settings | Input values passed to the indicator (up to 20) |
| 39 | Entry Condition Settings | What triggers a buy/sell |
| 40 | Exit Condition Settings | What triggers a close |
Orders pass throughthe same process as the panel’s BUY/SELL. The lot size is the panel’s LOTS, and stop loss and take profit use the settings from the panel's STOP/LIMIT as-is. Time filters and maximum spread checks are the same as well.
37. Read the Indicator
- 37-1. Indicator Usage Mode: 0=Entry only / 1=Exit only / 2=Entry & Exit both.
- 37-2. Indicator Name: From MT5’s
MQL5\Indicatorsfolder, input the name without the extension. If it’s in a subfolder, useFolderName\IndicatorNameformat. - 37-3. Indicator Timeframe: Default is the same bar as the chart.
- 37-4. Indicator Shift:0=forming bar (determined tick by tick), 1=the previous finalized bar (determined once when a new bar forms).
- 37-5. Entry Condition: 0=Always enter / 1=Only when no position (default) / 2=Only when no position in the same direction.
- 37-6〜37-9. Buffer Numbers: Buffers used for Buy/Sell/Buy close/Sell close.
- 37-10. Number of parameters passed to iCustom: Leave at the default -1 (auto).
Shifts are basically “1”
Shift 0 evaluates before the bar is finalized, sorepainting arrows that appear and disappear can be triggered. Backtests often look good, but in live trading this can cause false signals. Start with1 (finalized bar). Also, multiple entries in the same direction for the same bar are limited to one.
How to determine the buffer numbers
MT5’sData Window (Ctrl+D)shows the indicator values when you hover the mouse. Counts from 0 onward give you the approximate buffer numbers. If some calculation buffers aren’t displayed, it can shift; if it doesn’t line up, try shifting by one and testing.
38. Passing Parameters (MT5’s trickiest part)
In 38-1 to 38-20, enter the indicator’s input valuesfrom the top in order.
If 37-10 is -1 (auto), pass up to the last number in group 38 that is non-zero; if all are 0, use the indicator’s default values as is.That is the key.
- If you’re okay with the indicator’s default values,leave all of group 38 as 0.
- If you want to change only the first, entering only 38-1 will leave 2nd onward to the indicator’s default values.
- If you want to change the third, you need to enter the first two as well (with their default values).
In earlier versions, 20 values were always passed, so for indicators with fewer inputs, all defaults being 0 would overwrite and cause “signals not to fire” even though it seemed loaded. The current version reduces this issue, but if signals don’t appear, first try setting all 38 groups to 0.
※ Group 38 values are passed as numbers. If you input strings (like file names), use the indicator’s own default values for those.
39. Entry Conditions (Five signal types)
There are five types for both buy and sell.
| Type | Buy / Sell | Which indicators this is for |
|---|---|---|
| Signal | 39-1 / 39-2 | Indicates the arrow via a buffer. Triggers when it becomes non-zero or when it changes from 0 to + (buy) / 0 to − (sell) |
| Price Condition | 39-3〜39-5 / 39-6〜39-8 | Moving averages, bands, or other lines on the same scale as price. Trigger when price crosses above/below the line, or when price is above/below the line |
| Numeric Condition | 39-9〜39-11 / 39-12〜39-14 | Oscillators like RSI. Trigger when values cross above/below thresholds, or are above/below thresholds |
| Object | 39-15〜39-18 | Indicates arrows or text drawn as “chart objects.” Determined by part of the name |
| Arrow Code | 39-19〜39-22 | Arrow objects with arbitrary names. Determined by the symbol number |
The “price type” of price conditions (39-4, 39-7) is1=Closein MT5 by default.
If multiple conditions in the same direction are ON, you enter if any one of them is true (OR), not all (AND).Be careful: combinations like “arrow appears and RSI is above 50” cannot be done with this feature.
Taking signals from objects (39-15〜39-18)
For some indicators, arrows are drawn not via a buffer but aschart objects. Indicators that do not show values in the data window are usually of this type.
- Right-click the chart → Open “Object List” (Ctrl+B) and choose “Show All” to confirm the arrow names.
- Common substring in buy arrows (e.g.:
BUY_andUp) should be entered into39-17, and sells into39-18.Partial match; a part of the name is enough. - Set 39-15 and 39-16 to true.
Taking signals from arrow codes (39-19〜39-22)
If there is no naming rule or the numbers change every time,use the arrow symbol’s Wingdings numberto determine. The defaults are buy 233 (up arrow) and sell 234 (down arrow). If your indicator uses different symbols, check the symbol in the arrow’s properties and enter its number.
Notes when using objects/arrows
- Read on the chart that has ELDRA drawn on it. Keep the indicator on the same chart. If you determine only by objects and arrow codes, it will work even if the indicator name in 37-2 cannot be read.
- The determination is at the exact start time of the bar for the bar in 37-3 and 37-4’s shift. Indicators drawn in the middle of a bar will not trigger.
- When used for backtesting, make sure visually that the arrows are actually drawn.
40. Exit Conditions
Group 40 is the same shape as group 39, with the signal/price/numeric/object/arrow codes configured for exit. The default exit object names areEXIT_BUY_/EXIT_SELL_, and the exit arrow codes arebuy exit 234・sell exit 233(the opposite of the entry).
40-3. Exit by opposite signal is enabled by default. If you hold a buy and a sell signal appears, it closes the buy.
“Entry is you, exit is the indicator”
If you set 37-1 to1 (Exit only), you enter with BUY/SELL on the panel and leave exits to the indicator. This semi-discretionary use is my recommended approach.
Common mistakes
- Exit settings do not take effect: If 37-1 is 0 (Entry only), group 40 will not consider opposite-signal exits either andwill not show any signals. If you want exits handled automatically, set to 2.
- No signals appear: Try returning all 38 groups to 0 → shifting the buffer number by one → setting shift to 1, in that order.
- Enter too much: Are you setting 37-5 to 0 (Always enter)? The “upper/lower” price or numeric conditions will stay signaling as long as they are met, so pair with No Position-only or use “break above/below”.
- Mixing with averaging down (namping): The No Position in 37-5 counts positions added via averaging down.
Summary
- Specify the indicator, bar, and buffers in 37; keep 38 at default 0; use shift starting from 1.
- Signals in 39 are five types: Signal, Price, Numeric, Object, and Arrow Code. For the same direction, use OR logic.
- Objects/arrows read from the same chart’s indicator; read at the bar’s start time.
- In “Exit only” mode, you can have the entry done by you and let the indicator handle exits.
The indicator signals are best verified one by one in the backtest’s visual mode. Please validate settings and use at your own risk.
First, a trial version
There is a free trial for MT514-day. Try with your existing indicators to see if signals can be obtained through the tester.
- Trial (MT5, 14 days free):https://www.gogojungle.co.jp/tools/indicators/87634
- Product version (MT5):https://www.gogojungle.co.jp/tools/indicators/53197
- Product version (MT4):https://www.gogojungle.co.jp/tools/indicators/53092