Geek's DMI

Not an upgrade as much as a tweek.

DMI+/- are slightly smoother.

ADX was modified to be a field that is negative or positive, the value of which was multiplied to be highly visible.

Hope you like it.
Remove from Favorite Scripts Add to Favorite Scripts
Try this if you don't like the sensitivity of the previous version and prefer a smooth ADX -even simpler to tweak. (no edit option for posts?!)

study(title="Geek's DMI", shorttitle="G_DMI")
len = input(14, minval=1, title="DI Length")
lensig = input(14, title="ADX Smoothing", minval=1)

up = change(high)
down = -change(low)
plusDM = na(up) ? na : (up > down and up > 0 ? up : 0)
minusDM = na(down) ? na : (down > up and down > 0 ? down : 0)
trur = rma(tr, len)
plus = fixnan(100 * rma(plusDM, len) / trur)
minus = fixnan(100 * rma(minusDM, len) / trur)
sum = plus + minus
adx = 100 * rma((plus - minus) / (sum == 0 ? 1 : sum), lensig)
plot(adx, color=#d0b170, style=area, transp=40, title="DMX")
plot(plus, color=green, title="+DI")
plot(minus, color=red, title="-DI")

Home Stock Screener Forex Screener Crypto Screener Economic Calendar Shows How It Works Chart Features Pricing House Rules Moderators Website & Broker Solutions Widgets Charting Solutions Lightweight Charting Library Help Center Refer a friend Feature Request Blog & News FAQ Wiki Twitter
Profile Profile Settings Account and Billing Refer a friend My Support Tickets Help Center Ideas Published Followers Following Private Messages Chat Sign Out