OPEN-SOURCE SCRIPT

Ha Smooth Scalper

4 695
ha smooth scalper

ha smooth scalper is a trend-following and scalping tool built around smoothed heikin-ashi logic, real structure trend locking, multi-timeframe confirmation, higher-timeframe filtering, protected structure levels, clean candle coloring, and a compact professional dashboard.

the goal of this indicator is to help traders stay with the real trend instead of reacting to every small candle color change.

in a strong bullish slope, the tool can keep the chart bullish until a real protected swing low is broken.
in a strong bearish slope, the tool can keep the chart bearish until a real protected swing high is broken.

this makes the trend view cleaner and helps reduce false flips during strong directional moves.

main concept

most candle-based systems change color too quickly.

a single weak red candle inside a strong bullish trend should not always mean the trend is bearish.
a single weak green candle inside a strong bearish trend should not always mean the trend is bullish.

ha smooth scalper solves this by combining:

smoothed heikin-ashi calculation
real structure lock
protected swing highs and swing lows
multi-timeframe agreement
extra higher-timeframe confirmation
trend cloud
optional smooth candle mode
professional dashboard

how the trend works

the indicator first builds smoothed heikin-ashi candles from the chart data.

then it uses a structure lock system to decide if the market is really bullish or bearish.

bullish trend

the market stays bullish while price respects the protected swing low.

small bearish candles inside the bullish slope do not automatically flip the trend.

the trend changes to bearish only when the protected support structure is broken.

bearish trend

the market stays bearish while price respects the protected swing high.

small bullish candles inside the bearish slope do not automatically flip the trend.

the trend changes to bullish only when the protected resistance structure is broken.

protected structure level

the protected structure line shows the key level that must break before the trend can truly change.

in a bullish trend, this level is usually below price.
in a bearish trend, this level is usually above price.

for beginners, this is one of the most important parts of the tool.

if the market is bullish and price stays above the protected structure, the bullish trend remains valid.
if the market is bearish and price stays below the protected structure, the bearish trend remains valid.

smooth lock candle mode

smooth lock candle mode is designed to keep chart colors aligned with the real structure trend.

when enabled:

bullish structure keeps candles bullish
bearish structure keeps candles bearish
minor counter-trend candles are ignored
color changes only happen after real structure breaks

this mode is useful for traders who want a cleaner trend view and fewer emotional exits.

multi-timeframe confirmation

the indicator includes six selectable timeframes.

each timeframe can be enabled or disabled.

the panel shows whether each selected timeframe is bullish or bearish.

the minimum timeframe agreement setting controls how many selected timeframes must agree before a signal is accepted.

example:

if six timeframes are enabled and the minimum agreement is set to three, at least three selected timeframes must agree with the signal direction.

higher values create fewer but cleaner signals.
lower values create more signals but with more risk of noise.

extra htf confirmator

the extra higher-timeframe confirmator is an additional filter designed to reduce weak buy and sell signals.

it can confirm direction using:

ema slope plus price
or heikin-ashi direction

when enabled, long signals require bullish higher-timeframe confirmation.
short signals require bearish higher-timeframe confirmation.

this is useful because many losing trades happen when lower-timeframe signals go against the larger trend.

signal logic

long signal

a long signal can appear when:

the structure flips bullish
enough selected timeframes agree
the extra htf confirmator agrees
the trend mode allows long entries
the impulse filter confirms body expansion

short signal

a short signal can appear when:

the structure flips bearish
enough selected timeframes agree
the extra htf confirmator agrees
the trend mode allows short entries
the impulse filter confirms body expansion

full confluence star

a star appears when all selected timeframes agree with the signal direction.

this is a stronger confluence condition, but it should still be used with proper risk management.

dashboard

the dashboard is designed to give a fast view of the market.

it shows:

chart trend
six timeframe directions
multi-timeframe agreement
extra htf confirmation
structure lock status
protected structure price
smooth lock candle state
last signal

the panel uses a clean grey professional style and can be moved around the chart.

how to use the indicator

step 1: check the chart trend

start with the first dashboard row.

if the chart trend is bullish, focus mainly on long setups.
if the chart trend is bearish, focus mainly on short setups.

beginners should avoid trading directly against the displayed structure trend.

step 2: check the protected level

look at the protected structure level.

in a bullish trend, this is the important level below price.
if price stays above it, the bullish structure remains valid.

in a bearish trend, this is the important level above price.
if price stays below it, the bearish structure remains valid.

step 3: check timeframe agreement

look at the six timeframe rows.

cleaner long conditions usually appear when most selected timeframes are bullish.
cleaner short conditions usually appear when most selected timeframes are bearish.

step 4: check the htf confirmator

if the extra htf confirmator is enabled, wait for it to agree with the trade direction.

bullish htf confirmation supports long setups.
bearish htf confirmation supports short setups.

step 5: wait for a signal

a long signal marks a bullish structure transition with confirmation.
a short signal marks a bearish structure transition with confirmation.

do not trade every signal blindly.
always check trend context, support and resistance, volatility, session timing, and risk placement.

beginner long example

1. chart trend is bullish
2. smooth lock candle mode shows bullish structure
3. most selected timeframes are bullish
4. extra htf confirmator is bullish
5. price holds above the protected structure level
6. a long signal appears
7. stop loss can be planned below the protected level or below a recent swing low
8. target can be based on resistance, previous high, or a fixed risk/reward plan

beginner short example

1. chart trend is bearish
2. smooth lock candle mode shows bearish structure
3. most selected timeframes are bearish
4. extra htf confirmator is bearish
5. price holds below the protected structure level
6. a short signal appears
7. stop loss can be planned above the protected level or above a recent swing high
8. target can be based on support, previous low, or a fixed risk/reward plan

important settings

pre-smooth length

controls the first smoothing applied to price before the heikin-ashi calculation.

lower values react faster.
higher values are smoother.

post-smooth length

controls smoothing after the heikin-ashi calculation.

higher values reduce noise and false movement.
lower values make the tool more reactive.

slow baseline length

controls the slow baseline used for trend context and pullback logic.

structure pivot strength

controls how strong a swing high or swing low must be before it can become a protected structure level.

lower values react faster.
higher values create stronger but slower structure levels.

structure break confirmation

close mode requires candle close beyond the protected level.
wick mode reacts faster but can be noisier.

structure break buffer

adds an atr buffer beyond the protected level before the structure is considered broken.

higher buffer creates fewer trend flips.
lower buffer creates faster flips.

minimum timeframes agreeing

controls how many enabled timeframes must agree before a signal is allowed.

higher values are stricter.
lower values are more aggressive.

extra htf confirmator

adds a higher-timeframe direction filter to help avoid weak lower-timeframe signals.

smooth lock candle mode

keeps the visible candle color aligned with the structure trend until a real structure break happens.

best beginner settings

for cleaner trend reading:

enable real structure trend lock: on
structure source: raw price
structure break confirmation: close
smooth lock candle mode: on
extra htf confirmator: on
use confirmed mtf candles: on
minimum timeframes agreeing: 3 or higher
glow baseline: off
confluence background tint: off

for faster scalping:

structure pivot strength: 6 to 8
minimum timeframes agreeing: 2 to 3
extra htf confirmator: on
smooth lock candle mode: on

for safer trend following:

structure pivot strength: 10 to 14
minimum timeframes agreeing: 4 to 6
extra htf confirmator: on
structure break buffer: higher value

alerts

the indicator includes alerts for:

long scalp
short scalp
full bull
full bear
structure bull break
structure bear break

for cleaner alerts, use once per bar close.

risk management

this tool helps identify trend direction and filtered signals, but risk management is still required.

before entering a trade, define:

entry
stop loss
target
position size
invalidated condition

a good signal without risk management can still become a bad trade.

final note

ha smooth scalper is designed to make trend direction cleaner, reduce false color flips, and help traders focus on higher-quality conditions using structure, smoothing, multi-timeframe alignment, and higher-timeframe confirmation.

Declinazione di responsabilità

Le informazioni e le pubblicazioni non sono intese come, e non costituiscono, consulenza o raccomandazioni finanziarie, di investimento, di trading o di altro tipo fornite o approvate da TradingView. Per ulteriori informazioni, consultare i Termini di utilizzo.