OPEN-SOURCE SCRIPT

HalfTrend cross 2.0 Lcfx

70
Core Functionality
HalfTrend Baseline

Plots a dynamic trend-following line that alternates between blue (bullish) and red (bearish)

Uses amplitude and channel deviation settings to adapt to market volatility

Shows ATR-based channels around the trend line (optional)

Key Signals:

Reversal Signals: Traditional arrows at trend reversal points

Cross Signals: Basic "B"/"S" labels when price crosses the HalfTrend line

Re-Cross Signals: Special "RB"/"RS" labels for strategic re-entry opportunities

Unique Re-Cross Logic
Bullish Trend:

Triggers RB (Re-Cross Buy) only when:

Price first crosses BELOW HalfTrend (bearish cross)

Then crosses BACK ABOVE HalfTrend

Only the FIRST such occurrence in current bullish trend

Bright green "RB" label

Bearish Trend:

Triggers RS (Re-Cross Sell) only when:

Price first crosses ABOVE HalfTrend (bullish cross)

Then crosses BACK BELOW HalfTrend

Only the FIRST such occurrence in current bearish trend

Orange "RS" label

Smart Signal Management
Prevents signal spam by allowing only one re-cross signal per trend phase

Automatically resets signals when trend reverses

Dedicated alerts for all signal types

Customizable visual elements (colors, channels, arrows)

Practical Use Case
Identifies high-probability continuation entries:

RB signals: Potential add-to-position points in uptrends after minor pullbacks

RS signals: Shorting opportunities in downtrends after dead-cat bounces

This enhanced version reduces noise while highlighting strategic trade setups where price temporarily violates the trend line but quickly reconfirms the dominant trend direction.

Feragatname

Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.