Indicator · Pine Script v4 · Own pane

MACD Breakout

by jerryinyang

This indicator plots a higher-timeframe MACD breakout setup on the price chart and combines it with linear regression channels.

View on GitHub

GitHub stars5on the repository
Pine versionv4older, still runs
Lines of code728
Settings30inputs
LicenceNone stated
Last update2 years ago12 May 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

MACD Breakout marks support and resistance zones from MACD histogram sensitivity, then filters them with the MACD zero line, a linear regression filter, and optional zone invalidation. Channel length, deviation, and a second timeframe set the regression bands. ATR multiplier and reward-risk inputs place stop and target levels, with an optional reverse-entry mode. It is a study, so it does not place orders.

Details

Published by

jerryinyang on GitHub

Type

Indicator, Pine Script v4

Draws

Separate pane below the chart

Markets

Any symbol

Timeframes

Any timeframe

Risk Notes

No repainting, lookahead or stacked entries were found in its code or README. That says nothing about how well it works: test it first.

Settings

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

SettingTypeDefaultVariable
MACD TimeFramestring120i_htfRes
Macd Settingsstring8, 17mset
MACD signal Lineint9siglen
MACD Moving Average TypestringSMAmaType
MACD Sensitivityint5histSens
Use FilterboolfalseuseFilt
Use Macd Zero Line FilterbooltrueuseMacdFilt
Use Linear Regression Filter?booltrueuseLinRegFilt
Zone Invalidation?boolfalseentryInval
MF Overboughtint70mfOb
MF Oversoldint30mfOs
Sourcesourcecloselinreg_src
Show all 30 settings
SettingTypeDefaultVariable
Deviation 1float1.0dev1Len
Deviation 1float2.0dev2Len
Deviation 1float3.0dev3Len
Extend Lines?booltrueextendit
Show Broken Channelboolfalseshowbroken
Up Colorcolorcolor.limeupcol
Down Colorcolorcolor.reddncol
Line Widthint2widt
Channel 1 Lengthint100chann1Len
Channel 2 Lengthint50i_chann2Len
Channel 2 Timeframestring240chann2Res
Deviation as Basisint2useDev
Zone for Reversalint2revZone
ATR Multiplierfloat1slAtrMult
Reward-Risk Ratiofloat1.5tpRRR
Take Reverse Entries?boolfalseuseRev
Reward-Risk Ratio For Reverse Positionsfloat1revRRR
Add ATR Buffer for Reverse Positions?booltrueuseRevAtr
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

2 stars

The Fake Breakout / Breakdown Setup indicator identifies false breakouts (FBO) and false breakdowns (FBD) by tracking liquidity sweeps of previous price highs and lows. It validates reversals using follow-up price action and a confirmation scoring system based

Indicator v6 BreakoutOscillators & momentum
Updated 8 weeks ago · None stated GitHub repository of Fake Breakout / Breakdown Setup

Chop and Explode

by capissimo
114 stars

This indicator measures market consolidation and breakout phases by computing a scaled Relative Strength Index (RSI) on normalized price data. It identifies chop zones when the RSI oscillates between 40 and 60, highlighting tight consolidation between 45 and 5

Indicator v5 Oscillators & momentumVolatility & bands
Updated 1 year ago · None stated GitHub repository of Chop and Explode

Squeeze Momentum

by mihakralj
99 stars

This indicator plots Squeeze Momentum in a separate pane. It compares Bollinger Bands with a Keltner Channel to mark a squeeze when the bands sit inside the channel. Momentum is a linear regression of price relative to a Donchian midline and an SMA, shown as a

Indicator v6 Volatility & bandsOscillators & momentum
Updated 4 weeks ago · Apache-2.0 GitHub repository of Squeeze Momentum

CCI DC

by be-thomas
65 stars

This indicator plots the Commodity Channel Index in a separate pane and surrounds it with a Donchian channel whose lookback length changes with volatility. It measures volatility as a ratio of short and long ATR values, then ranks that ratio and shortens or le

Indicator v5 Oscillators & momentumVolatility & bands
Updated 6 days ago · GPL-3.0 GitHub repository of CCI DC

Renko Acceleration

by f-cksociety
11 stars

Calculates the time elapsed between consecutive bars to measure market speed and volatility, designed primarily for Renko chart blocks where bar duration varies. In Momentum mode, it contrasts the current duration against a 100-period moving average baseline,

Indicator v4 Volatility & bandsOscillators & momentum
Updated 4 years ago · MPL-2.0 GitHub repository of Renko Acceleration

Market Pressure Scale plots two oscillator curves in a separate pane. Setup pressure combines ATR and Bollinger compression, support and resistance proximity, and drying volume. Impulse pressure combines range expansion, volume, and candle body size. A range-c

Indicator v6 Oscillators & momentumVolatility & bands
Updated 3 days ago · MIT GitHub repository of Market Pressure Scale [WavesUnchained]

More Oscillators & momentum scripts

Related on ForexR

Trade Your Charts With a Regulated Broker

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

Compare brokers