- Momentum
- On price
- Intermediate
Marks the first candle where both trend (EMA 13) and momentum (MACD histogram) turn the same way, following Alexander Elder's Impulse System colours. A marker appears only when the state changes, not on every green or red candle.
The rules
HIGHER marker
EMA 13 is rising and the MACD(12, 26, 9) histogram is rising (green impulse) on a candle after a candle that was not green.
LOWER marker
EMA 13 is falling and the MACD(12, 26, 9) histogram is falling (red impulse) on a candle after a candle that was not red.
A marker appears after the next candle opens and is drawn on the candle that completed the setup. It is a chart observation, not an instruction to trade.
How to read it
The amber line is EMA 13. A green HIGHER triangle under a candle marks the first green impulse after a pause; a red LOWER triangle above a candle marks the first red impulse. Turn on 'Impulse candles' to paint candles green, red or grey as in the original Elder system.
Indicators used
- EMA (13)
- MACD histogram (12, 26, 9)
Same view with built-in indicators: Add Elder Impulse System (EMA 13, MACD 12/26/9) from the IQ Option indicator list.
Default settings
| EMA period | 13 |
|---|---|
| MACD fast | 12 |
| MACD slow | 26 |
| MACD signal | 9 |
| Colour candles by impulse | off |
Every value is an input in the script settings. Platform advice is off by default.
Key points
- The Elder Impulse System asks two questions: is the 13-period EMA rising, and is the MACD histogram rising?
- If both say yes the impulse is green; if both say no it is red; if they disagree it is neutral.
- The script marks only the first green candle after a non-green one as HIGHER.
- The first red candle after a non-red one is marked LOWER.
- That keeps the chart clean: one marker when the impulse starts, not one per candle.
- Check it against the built-in MACD on a Practice balance first.
Limitations. Both inputs must agree, so the marker usually arrives after part of the move has happened, and in sideways markets the impulse flips between states quickly. The MACD histogram itself is not drawn in the overlay; add the built-in MACD to see it. The official indicator colours every candle, while this script marks only the first one. Test on the Practice balance before risking real funds.
Install it in four steps
- Download and inspectDownload one .lua file and open it in a plain-text editor if you want to read it first. If you downloaded the ZIP, extract it.
- Open Chart Analysis → ScriptsIn the IQ Option traderoom, choose the Practice balance, open the chart analysis panel, select Scripts and choose Import script.
- Save and add to chartSelect the downloaded file, review the imported code, choose Save, then use the + control to add it to the chart.
- Change one input at a timeConfirm the default view first. Then adjust periods, levels or colours one setting at a time and note what changes.
Complete source code
The download and this preview resolve to the same reviewed file. SHA-256: dade251e30711576e848ba137ed11475d61d3914a2dc214ca65c8d318e5039e2
-- SPDX-License-Identifier: MIT
-- IQOptionWiki QCS Library
-- IQOW Elder Impulse v1.0.0
--
-- Elder Impulse System: the 13-period EMA gives trend direction and the MACD
-- histogram gives momentum. When both rise the impulse is green; when both
-- fall it is red; otherwise neutral. Formulas follow the official indicator.
--
-- HIGHER: the first candle where EMA 13 is rising and the MACD(12,26,9)
-- histogram is rising (green impulse) after a non-green candle.
-- LOWER: the first candle where both are falling (red impulse) after a
-- non-red candle.
--
-- Markers use the previous completed candle: they appear after the next candle
-- opens and are shifted back one bar onto the candle that qualified.
-- Educational chart tool only. It does not place trades, choose an expiry,
-- predict outcomes, or guarantee results. Test on a Practice balance first.
instrument {
name = "IQOW Elder Impulse",
short_name = "IQOW ELDER",
overlay = true
}
input_group {
"1. Trend EMA",
ema_period = input (13, "EMA period", input.integer, 2, 200)
}
input_group {
"2. MACD histogram",
fast_period = input (12, "Fast period", input.integer, 2, 100),
slow_period = input (26, "Slow period", input.integer, 3, 200),
signal_period = input (9, "Signal period", input.integer, 2, 100)
}
input_group {
"Display and advice",
lines_visible = input { default = true, type = input.plot_visibility },
impulse_candles_visible = input { default = false, type = input.plot_visibility },
signals_visible = input { default = true, type = input.plot_visibility },
advice_enabled = input { default = false, name = "Enable platform advice", type = input.boolean }
}
input_group {
"Colors",
ema_color = input { default = "#FFB020", type = input.color },
impulse_up_color = input { default = "#2CAC40", type = input.color },
impulse_neutral_color = input { default = "#C7CAD1", type = input.color },
impulse_down_color = input { default = "#DB4931", type = input.color },
line_width = input { default = 1, type = input.line_width },
higher_color = input { default = "#25E154", type = input.color },
lower_color = input { default = "#FF6C58", type = input.color },
signal_text_color = input { default = "#FFFFFF", type = input.color }
}
-- Trend: EMA 13. Momentum: MACD histogram (MACD minus its SMA signal line).
trend_ema = ema (close, ema_period)
macd_line = ema (close, fast_period) - ema (close, slow_period)
macd_histogram = macd_line - sma (macd_line, signal_period)
-- Current-bar scalars for the Lua rule logic.
local ema_now = get_value (trend_ema, nil)
local ema_before = get_value (trend_ema [1], nil)
local hist_now = get_value (macd_histogram, nil)
local hist_before = get_value (macd_histogram [1], nil)
local periods_are_valid = fast_period < slow_period
local data_is_ready =
periods_are_valid and
ema_now ~= nil and
ema_before ~= nil and
hist_now ~= nil and
hist_before ~= nil and
get_value (macd_histogram [slow_period + signal_period], nil) ~= nil
-- Impulse state on this candle. Markers fire when the state first appears.
local impulse_is_green = data_is_ready and ema_now > ema_before and hist_now > hist_before
local impulse_is_red = data_is_ready and ema_now < ema_before and hist_now < hist_before
higher_setup = conditional (impulse_is_green)
lower_setup = conditional (impulse_is_red)
-- Confirm only a new setup on the previous completed candle.
confirmed_higher = conditional (
get_value (higher_setup [1], false) and
not get_value (higher_setup [2], false)
)
confirmed_lower = conditional (
get_value (lower_setup [1], false) and
not get_value (lower_setup [2], false)
)
if lines_visible then
plot (trend_ema, "EMA trend", ema_color, line_width)
end
-- Optional impulse-coloured copy of the price candles.
if impulse_candles_visible then
local impulse_color = impulse_is_green and impulse_up_color
or (impulse_is_red and impulse_down_color or impulse_neutral_color)
plot_candle (open, high, low, close, "Impulse candles", impulse_color)
end
if signals_visible then
plot_shape (
confirmed_higher,
"ELDER HIGHER",
shape_style.triangleup,
shape_size.small,
higher_color,
shape_location.belowbar,
-1,
"HIGHER",
signal_text_color
)
plot_shape (
confirmed_lower,
"ELDER LOWER",
shape_style.triangledown,
shape_size.small,
lower_color,
shape_location.abovebar,
-1,
"LOWER",
signal_text_color
)
end
-- QCS advice is a platform notification state only; it does not place trades.
if advice_enabled and
get_value (confirmed_higher, false) and
not get_value (confirmed_lower, false) then
advise (advice.buy)
elseif advice_enabled and
get_value (confirmed_lower, false) and
not get_value (confirmed_higher, false) then
advise (advice.sell)
else
advise (advice.neutral)
end
More momentum scripts
- Momentum
- Context indicator
- Own panel
- Beginner
Price EMA Distance Percent
Shows how far the selected price source is above or below an EMA in percentage terms. A configurable reference zone helps compare the current distance with your chosen scale.
Indicators: EMA (20) distance in %
- Momentum
- Signal engine
- On price
- Advanced
IQ_WIKI_SCRIP_V1.1.0
A completed-candle adaptation of the regular IQOptionWiki Signals score. It weighs RSI, MACD, Bollinger %B, five directional candle patterns and optional chart-volume confirmation into one score and marks new qualifying setups.
Indicators: RSI · MACD · Bollinger %B (population deviation) · Five candlestick patterns · Optional chart volume
- Momentum
- Signal engine
- On price
- Advanced
IQ_WIKI_BINARY_SIGNAL_GUN_V1.1.0
A stricter local confluence engine with weighted RSI, ATR-normalized MACD, Bollinger and pattern-family votes. Optional strategy alignment must agree with the base direction.
Indicators: Weighted RSI · ATR-normalized MACD · Bollinger · Pattern families · ATR risk
Download all 56 scripts as one ZIP · MIT License, provided “as is”, without warranty. IQOptionWiki is independent of the IQ Option platform operator. Nothing here is investment advice or a guarantee of results.