OPEN-SOURCE SCRIPT
D/K Strength + Smart Money Accumulation

A multi-component momentum and accumulation oscillator adapted from the Wenhua/TDX (Chinese trading platforms) community formula "多空力度 + 主力吸筹 文华专用 稳定版".
— LINES PLOTTED —
• Long Strength (green)
A double-smoothed stochastic momentum on a 27-bar window, using the formula 3*SMA(stoch,5,1) - 2*SMA(SMA(stoch,5,1),3,1). Rising from low levels signals strengthening demand. Readings above 90 indicate extended bullish momentum.
• Short Strength (red)
Distance of close from the 55-bar high, normalized to 0–100. Persistent readings above the 44 midline reflect bearish pressure; values near 100 mean price is at a 55-bar low.
• Smart Money Accumulation (yellow)
A volume-free proxy detecting potential accumulation at the 30-bar low. Spikes above zero — especially appearing after a downtrend — are interpreted as buying pressure from larger participants.
— REFERENCE LEVELS —
0 = zero axis
44 = mid-line (long/short pressure boundary)
90 = overbought / overextended threshold
— HIDDEN DEBUG OUTPUTS (toggle in Settings → Style) —
J — classic KDJ J line (3K - 2D)
A65 — KD crossover marker (60 on bullish cross, 0 otherwise)
A151/A152 — deep oversold / overbought flags
Anquan — safety zone value
— TECHNICAL NOTE —
The original formula uses a recursive weighted average:
SMA(X, N, M) = (M*X + (N-M)*prev) / N
which is NOT equivalent to Pine's ta.sma. This implementation faithfully replicates the recursive form via inline state variables, preserving the original signal shape. All divisions are guarded against zero denominators.
— SUGGESTED USE —
• Long bias: Long Strength crossing above Short Strength while Accumulation spikes above zero.
• Short bias: Long Strength rolling over from 90 with Short Strength rising through the midline.
• Works on equities, futures and crypto. Best results on daily and 4-hour timeframes; usable on intraday with parameter awareness.
• Pair with the companion "Protection Price" overlay indicator for entry and stop reference.
A faithful Pine v6 port of the original community formula. Author of the original formula unknown.
— LINES PLOTTED —
• Long Strength (green)
A double-smoothed stochastic momentum on a 27-bar window, using the formula 3*SMA(stoch,5,1) - 2*SMA(SMA(stoch,5,1),3,1). Rising from low levels signals strengthening demand. Readings above 90 indicate extended bullish momentum.
• Short Strength (red)
Distance of close from the 55-bar high, normalized to 0–100. Persistent readings above the 44 midline reflect bearish pressure; values near 100 mean price is at a 55-bar low.
• Smart Money Accumulation (yellow)
A volume-free proxy detecting potential accumulation at the 30-bar low. Spikes above zero — especially appearing after a downtrend — are interpreted as buying pressure from larger participants.
— REFERENCE LEVELS —
0 = zero axis
44 = mid-line (long/short pressure boundary)
90 = overbought / overextended threshold
— HIDDEN DEBUG OUTPUTS (toggle in Settings → Style) —
J — classic KDJ J line (3K - 2D)
A65 — KD crossover marker (60 on bullish cross, 0 otherwise)
A151/A152 — deep oversold / overbought flags
Anquan — safety zone value
— TECHNICAL NOTE —
The original formula uses a recursive weighted average:
SMA(X, N, M) = (M*X + (N-M)*prev) / N
which is NOT equivalent to Pine's ta.sma. This implementation faithfully replicates the recursive form via inline state variables, preserving the original signal shape. All divisions are guarded against zero denominators.
— SUGGESTED USE —
• Long bias: Long Strength crossing above Short Strength while Accumulation spikes above zero.
• Short bias: Long Strength rolling over from 90 with Short Strength rising through the midline.
• Works on equities, futures and crypto. Best results on daily and 4-hour timeframes; usable on intraday with parameter awareness.
• Pair with the companion "Protection Price" overlay indicator for entry and stop reference.
A faithful Pine v6 port of the original community formula. Author of the original formula unknown.
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。