Bull and Bear Power

Bull and Bear Power

The financial markets are often described as a constant tug-of-war between buyers (Bulls) and sellers (Bears). Understanding who is currently winning this battle is the key to identifying trends and potential reversals.

The Bull and Bear Power indicator by LefAlgo is a sophisticated evolution of Dr. Alexander Elder’s classic Elder-Ray Index. While the original concept separates Bull Power and Bear Power into two different histograms, this version combines them into a single, comprehensive oscillator. Furthermore, it introduces a normalization algorithm that allows traders to gauge the intensity of the move relative to recent history, regardless of the asset’s price scale.

How it Works

The core logic of this indicator relies on the relationship between the price extremes (High and Low) and an Exponential Moving Average (EMA).

  1. Bull Power: Calculates the ability of buyers to push prices above the average consensus (High - EMA).

  2. Bear Power: Calculates the ability of sellers to push prices below the average consensus (Low - EMA).

  3. Net Sentiment: The indicator sums these two values to derive a net result (bbP).

If the result is positive, the Bulls are exerting more force. If negative, the Bears are in control.

Key Features

What sets LefAlgo’s version apart are two specific enhancements found in the code:

1. Adaptive Normalization Raw values can be difficult to interpret when switching between assets with different prices (e.g., EUR/USD vs. DAX). This indicator includes a normalization feature (isNormalized).

  • When active, the code tracks the highest and lowest values of the oscillator over the lookback period.

  • It then re-scales the current value to a range, making it easier to identify overextended conditions visually.

2. Signal Smoothing The indicator plots a Signal Line (displayed in blue). This is a moving average of the Bull/Bear power itself. This line helps filter out market noise and provides clearer crossover signals for trend following.

Configuration & Settings

You can modify the following variables in the indicator settings window to fit your trading style:

  • lengthInput (Default: 50): The number of periods used for the baseline Exponential Moving Average. Increasing this value makes the indicator less sensitive and better suited for long-term trends.

  • maLength (Default: 50): The length of the Signal Line (Moving Average of the oscillator). A lower value will make the signal line hug the histogram closer, while a higher value will smooth it out.

  • isNormalized (Default: 1): A switch to toggle normalization.

    • 1: Normalization is ON. The indicator adapts to the recent volatility range.

    • 0: Normalization is OFF. The indicator displays raw price values.

Trading Application

  • Zero Line Crossovers: The most direct signal is the crossover of the zero line. When the histogram turns Green (crosses over 0), it indicates that Bullish pressure has overcome Bearish pressure. Conversely, a switch to Red (crosses under 0) suggests the Bears have taken control.

  • Trend Strength: The height of the histogram bars represents the intensity of the trend. In the normalized mode, extreme readings may suggest a potential exhaustion of the current move.

  • Signal Line Filtering: You can use the blue Signal Line as a filter. For example, only taking long positions when the histogram is above the Signal Line.

The Code

You can copy and paste the following code into your ProRealTime platform window:

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials

avatar
Register or

Likes

avatar
Related users ' posts
s00071609 Hi, could you please suggest, what this codes gives, lowest[b](rsi[a]) -- just trying to us...
Nicolas lowest[b](rsi[a]) returns the lowest values of the RSI of "a" periods, over the last "b" per...
s00071609 Hi, what would be the code to get the price for last bullish DTOSC cross over. I am looking ...
lglmrc Can't make it work, says: "Define p variable"
Ezio Hi Xel and thanks, do you know if there is a way in PRC of reading/counting intraday ticks?...
inadis ive just discovered this, i must say very nice thanks.

Top