Indicator · Pine Script v4 · On the chart

HMA-Kahlman Trend, DifferenceFilter & Trendlines

by capissimo

This indicator combines Hull Moving Average variations with optional Kalman filter smoothing, difference-based activity filtering, and pivot trendlines on the price chart.

View on GitHub

Repaints

GitHub stars114on the repository
Pine versionv4older, still runs
Lines of code105
Settings13inputs
LicenceNone stated
Last update1 year ago7 Nov 2024

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new indicator, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart, then adjust the settings with the gear icon next to its name.

Source Code

The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.

Overview

HMA-Kahlman Trend, DifferenceFilter & Trendlines calculates standard and three-pole HMAs, smooths them with a Kalman algorithm, and plots a dynamic trend ribbon. Buy and sell labels trigger on line crossovers, provided the scaled volume or high-low range exceeds its moving average threshold. An integrated pivot module projects trendlines across swing points. An optional repainting toggle is enabled by default to use unconfirmed live-bar values.

Details

Published by

capissimo on GitHub

Type

Indicator, Pine Script v4

Draws

On the price chart

Category

Trend, Moving averages, Support & resistance, Volume

Markets

Any symbol

Timeframes

Any timeframe

Risk Notes

  • Signals can change on the live bar or after it closes (repainting)

Settings

The inputs you can change from the gear icon on the chart. Defaults are the author's.

SettingTypeDefaultVariable
Price Datasourcehl2price
===HMA-Kahlman Trend Module===booltruehkmod
Lookback Windowint22length
Use Kahlman?booltruek
Gainfloat.7gain
Show Labels?booltruelabels
Repainting?booltruerep
===Winsorizing Module===booltruewsmod
Filtering MethodstringHigh-Lowmethod
Clipping Lookback Windowint20p
Threshold Increment (1.0== none)float1.5inc
===Trendlines Module===booltruetlmod
Show all 13 settings
SettingTypeDefaultVariable
Pivots Lookback Windowint2l1
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

IFA-VP Context

by eddiebelaval
7 stars

This indicator plots a fixed lookback Volume Profile alongside 20, 50, and 200 Simple Moving Averages directly on the price chart. It highlights trend changes via moving average crosses and marks Point of Control reactions, High Volume Nodes, and Value Area bo

Indicator v6 VolumeSupport & resistance
Updated 3 months ago · None stated GitHub repository of IFA-VP Context

Ichimoku Cloud

by harryguiacorn
219 stars

This indicator plots Ichimoku Cloud elements on the price chart, including Tenkan-sen, Kijun-sen, Senkou Span A and B lines with optional Chikou Span. It signals trend changes via Tenkan-sen and Kijun-sen crosses and places arrows at Kijun-sen direction shifts

Indicator v5 TrendMoving averages
Updated 1 year ago · None stated GitHub repository of Ichimoku Cloud

Midnight VWAP

by TradersPost
218 stars

The Midnight VWAP indicator calculates and overlays two distinct Volume Weighted Average Price (VWAP) lines on the price chart based on customizable session timeframes. It tracks an overnight or pre-market session alongside regular trading hours, resetting cal

Indicator v6 Moving averagesSessions & time
Updated 3 months ago · None stated GitHub repository of Midnight VWAP

MA Envelope (MAE)

by mihakralj
99 stars

The MA Envelope indicator calculates upper and lower channel bands shifted by a user-defined percentage around a baseline moving average. It supports Simple Moving Average, Exponential Moving Average, and Weighted Moving Average calculation types. The script p

Indicator v6 Moving averagesSupport & resistance
Updated 4 weeks ago · Apache-2.0 GitHub repository of MA Envelope (MAE)

More indicators

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers