Trend

Adx Dmi Trend

Wilder's Directional Movement system: buys when +DI is above -DI while ADX confirms the trend is strong (above 25), and sells when +DI crosses back below -DI.

Total score 42/ 100 rank 21 / 42 · trend 11 / 20

How It Works

  1. From each bar's high and low, compute the 14-bar +DI and −DI — how much of the recent movement has been upward versus downward — and ADX, which measures how decisively one side is winning.
  2. Buy when +DI sits above −DI and ADX is above 25 at the same time: the direction is up and the move is strong enough to be a trend rather than noise inside a range.
  3. Sell when +DI crosses back below −DI. The exit deliberately does not wait on ADX — a fading ADX with price rolling over would otherwise strand the position.

Worked example. +DI climbs to 28 while −DI slips to 14 and ADX pushes through 25, so the strategy buys at 100. The trend runs to 118 before the lines converge and +DI drops under −DI, closing the trade for an 18% gain. A later stretch where +DI leads but ADX sits at 18 is skipped entirely — direction without strength is the chop this filter exists to avoid.

The Math Behind The Indicators

Everything runs on closing prices of the traded timeframe: P is a close, Pt today's close, and N counts bars — one bar is one candle of that timeframe, so 20 bars on a 1h chart is 20 hours.

Directional Movement (+DI, −DI, ADX)
Wilder's answer to two separate questions: which way is the market moving, and does the move deserve the name trend. Each bar is compared with the last — the part of today's high that pokes above yesterday's is up movement, the part of today's low that drops below yesterday's is down movement, and only the larger of the two counts. Smoothed over N bars and divided by the average true range, they become +DI and −DI. ADX then measures how far apart those two lines sit, so it rises in a strong move in either direction and falls to single digits when price is going nowhere. Because it reads the bar's high and low, it sees intrabar range that a close-only indicator cannot.
+DI = 100 EMAN(+DM)ATRN,    −DI = 100 EMAN(−DM)ATRN,    ADX = 100 · EMAN(| +DI − −DI |+DI + −DI)
Example: If +DI is 30 and −DI is 10, buyers are clearly winning: the gap ratio is |30 − 10| / (30 + 10) = 0.5, so ADX is pulled toward 50 — a strong trend. When the two lines converge to 20 and 18 the ratio collapses to 0.05 and ADX sinks toward 5, marking a range where direction means little.

Example Chart

Example Chart

The Metrics

Metric Calculation What it shows
Price Change % change = Plast − P0P0 × 100 The traded market's own close against its first close over the same window, as a percentage. What the market did while the rule was running — the benchmark every other row here is read against. A rule that made 40% in a market that made 120% lost to doing nothing.
Trades N = count(closed positions) How many positions the rule opened and closed over the window. The sample behind every other figure, and what the fees are charged on. Two rules with the same return are not the same rule if one took nine trades and the other took nine hundred.
Win Rate % W%n = winsnn × 100 Of the first n trades, how many closed above the cash they opened with after fees. Plotted trade by trade, so the line is the rate so far rather than a final figure. How often the rule is right, which is not how much it makes. A rule can win a third of its trades and still lead, if the third it wins pays for the two it loses.
Cumulative P&L % PnL%n = n∑i=1(fi − 1) × 100 Each trade's percentage result added up, net of fees. A sum rather than a compounding, so a 10% gain and a 10% loss cancel. What the rule returned per trade, with position size taken out of it. It answers whether the edge is in the trades themselves, where the equity curve answers what the account did with them.
Equity En = E0 n∏i=1fi The account compounded through every trade — the whole balance goes into the next position. Drawn net of fees as a solid line and gross of them as a dotted one. The account itself, which is the only figure a reader actually ends up with. The gap between the two lines is what the fees took, and it widens with every trade rather than staying a fixed share.
Cumulative Fees Fn = n∑i=1(Ci φ + Xi φ) Fee charged on the way into each position and again on the way out, at rate phi, on the capital actually committed — so the bill grows with the account as well as with the trade count. The cost of trading, in the account's own units. It is the one line here that only ever rises, and the one a rule cannot trade its way out of.
Rolling Sharpe Sharpet = mean(rdaily)sd(rdaily) × √365 Mean daily return over its deviation, annualized on a 365-day year because crypto has no weekend. Taken on the account marked to market every bar — open positions included, not just closed ones — and read off at each trade's exit. Return per unit of the swing it took to get it. It is the heaviest weight in the composite score, because an account that doubled calmly and one that doubled violently are not the same result.

Real Data

37/ 100Composite score

Metrics Per Trade

Final Metrics

Scores

Resampled Data

48/ 100Composite score

Metrics Per Trade

Final Metrics

Scores