Skip to content
All library documents

Trend Strength Index: Pearson Correlation of Price and Bar Index

Article MQL5 code base

Summary

The Trend Strength Index describes trend direction and linear consistency by calculating the Pearson correlation between closing prices and bar indices over a chosen lookback. The coefficient ranges from -1 to 1: values near 1 indicate a strong upward linear trend, values near -1 indicate a strong downward trend, and values near zero suggest little linear relationship and possibly sideways movement.

The document characterizes the measure as similar to a simplified autoregression indicator, but gives no formula details beyond the correlation inputs, no guidance on selecting the lookback, and no trading rules for entries or exits. It also provides no backtest or evidence that the indicator predicts future returns. Correlation summarizes how closely price moves along a straight line across the selected bars; it does not by itself establish trend durability or account for trading costs. A correction note says an update issue was fixed, but supplies no further technical details.

Key ideas

  • The indicator correlates closing prices with bar indices over a selected lookback.
  • Its output ranges from -1 to 1 and conveys both direction and linear strength.
  • Values near zero may indicate sideways movement, but do not establish it conclusively.
  • The document provides no tested trading rules or performance evidence.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.