OPEN-SOURCE SCRIPT
Momentum Consensus

Momentum Consensus reduces three momentum readings to a single agreement view. Each of DI-Power, BBP and the MACD-V histogram is reduced to its sign (above zero, below zero, or exactly zero), and the pane shows the net as one column: its height is the count above zero minus the count below zero (range -3 to +3), green and pointing up when bulls lead, red and pointing down when bears lead, and nothing when the two sides cancel. Only one side is ever drawn, so the column itself is the net stance. All three inputs are momentum or trend readings - DI-Power is (DI+ minus DI-) weighted by ADX, BBP is Elder Bull Bear Power over ATR, and MACD-V is the ATR-normalized MACD histogram - so the tally is a clean read of momentum agreement rather than a mix of different dimensions. Each reading is divided by its own rolling maxAbs; that scaling never subtracts a baseline, so each keeps its true zero and sign, and since the tally reads sign only, the scaling does not change the count, it just keeps each reading matching its source. When exactly one reading is on a side, a one-letter badge marks the lone reading (D for DI-Power, B for BBP, M for MACD-V) in its own colour, pinned to the top edge for a lone bull and the bottom edge for a lone bear so it never overlaps the column. Two alerts are available for when the net flips sides (its sign crosses zero), one for each direction. Everything is inferred from OHLCV. Built on public, well-documented concepts, implemented from scratch in original Pine. Descriptive context only, not a signal and not financial advice.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.