WeightedClose

Category: Constants

The WeightedClose function in ProBuilder language calculates a modified closing price of a stock or security that gives more importance to the closing price while also considering the high and low prices of the day. This indicator is used to provide a more comprehensive view of the day’s price movement compared to a simple closing price.

Syntax:

WeightedClose[N]

Where N represents the number of periods before the current one. For example, WeightedClose[1] refers to the weighted close of the previous candle.

Calculation:

The Weighted Close is calculated using the formula:

(2 * Close + High + Low) / 4

This formula averages the values by giving double weight to the closing price and single weight to both the high and low prices of the period.

Example:

To calculate the Weighted Close of the previous candle in a trading script, you can use the following code:

myWeightedClose = WeightedClose[1]

This line of code assigns the weighted close value of the previous candle to the variable myWeightedClose.

Additional Information:

  • The Weighted Close can provide a more balanced view of the market’s behavior by emphasizing the closing price, which is often considered the most important price of the day in many trading analyses.
  • This indicator is particularly useful in price trend analysis and can be used in conjunction with other indicators to make informed trading decisions.

Understanding and utilizing the Weighted Close can enhance the analysis of price patterns and trends, aiding in more effective trading strategies.

Logo Logo
Loading...