Does Half Trend repaint?
Two tests: one on closed bars, one on every tick inside the bar. Half Trend passes the first and not the second. Here are both results, the raw data, and what it means if you trade it.
Not on closed bars — but about 1 in 10 of its arrows disappears before the bar closes. Once a bar has closed, Half Trend never changed it: 0 values changed across 22,111 bars of gold. Inside the bar it is a different story: replayed on 306.8 million real ticks, 73 arrows appeared and were gone by the close — 10% of every arrow it showed.
Half Trend is one of the most popular free trend indicators for MetaTrader, and “does it repaint?” is one of the most asked questions about it. The honest answer needs two tests, because the word covers two different things. We ran both.
What was tested
- The indicator:
Half_Trend_New_Alert.mq5by Vladimir Karputov, from the MQL5 Code Base. Default settings (amplitude 5). - The market: XAUUSD, 1-hour chart, January 2023 to October 2026: 22,111 bars.
- Test 1, closed bars: each bar’s values recorded the moment it closes, then read again fifty bars later. How the test works.
- Test 2, inside the bar: the arrow buffers read on every single tick of the forming bar — 306.8 million real ticks — and compared with what the finished bar shows.
Test 1: closed bars — passed
arrows printed 643
values changed 0
Half Trend only looks back, never forward, and once a bar has closed it does not touch it again. By the strict definition — a closed bar must never change — Half Trend does not repaint. That is better than plenty of paid indicators, and it deserves saying plainly.
Test 2: inside the bar — the arrows that vanish
While a bar is still forming, Half Trend recalculates it on every tick. When price pushes far enough, the line flips and an arrow appears. When price comes back before the close, the flip is undone and the arrow is gone. This is what people mean when they say Half Trend “repaints”.
arrows that vanished 73 (10% of all arrows shown)
on screen before vanishing 24 min typical, 59 min longest
shown 15 minutes or more 52 of 73
These are not flickers you would never notice. Every one of them appeared within the first minute of its bar, and most stayed on screen for a quarter of an hour or longer — plenty of time to see it, believe it and act on it. On the finished chart, none of them exists.
By the definition on our non-repaint page, this is not
repainting: the bar was still forming, and an arrow on a forming bar is a provisional arrow. It matters anyway,
for one reason — Half Trend’s own alert fires on the forming bar. Its code checks the newest bar
(rates_total-1) for an arrow, so each of these 73 arrows would also have sent you an alert for
a signal that is not on the chart afterwards.
What it means if you use it
- Act only after the bar closes. An arrow that is still there when the next bar opens is final; Test 1 proves it. Every vanished arrow in this test was on a bar that had not closed yet.
- Do not trade the alert as it arrives. Wait for the close, or use a version whose alert checks the previous, finished bar instead of the current one.
- Judging it by its history is fair. Unlike centered indicators, its past arrows were all available when their bar closed. What history cannot show you is the 73 arrows that came and went.
The same two tests on Agimat FX
We run every test on our own indicator first. Agimat FX Gold, same market, same bars, same 306.8 million real ticks:
arrows that vanished 0 of 1,102
An Agimat FX arrow that appears is the arrow that stays — on the forming bar, at the close and fifty bars later. Non-repainting is the minimum, not the reason to buy it: what it adds is shown on real charts and in a short video on the home page — signals from the daily chart down to one minute, and an EA that can take them for you and let winners run behind a trailing stop.
Check it yourself
- halftrend-repaint-audit.csv — Test 1, every bar and buffer, at the close and fifty bars later · config: halftrend-repaint.ini
- halftrend-intrabar-audit.csv — Test 2, every arrow, whether it stayed, when it first and last showed · config: halftrend-intrabar.ini
- agimat-intrabar-audit.csv — Test 2 on Agimat FX · config: agimat-intrabar.ini
- IndiProbe.ex5 and IntrabarProbe.ex5 — both probes, to run the same tests on any indicator you own
Be told when the new build is ready
One message. Nothing else, ever.
The list hears first.