Skip to content
All library documents

Using ACF and PACF Plots to Examine Time-Series Dependence

Article MQL5 code base

Summary

This brief document describes a charting script that calculates and displays the autocorrelation function (ACF) and partial autocorrelation function (PACF) for a selected data window. Its inputs control the number of observations, the number of lags, the offset from the most recent bar, and how long the chart remains visible. The stated defaults use a window of 100 observations, 16 lags, zero offset, and a 10-second display duration.

ACF and PACF plots are descriptive tools for examining serial dependence and can help researchers inspect lag structure before modeling a financial time series. The note does not explain inference, stationarity requirements, confidence bands, or how to translate a plotted pattern into a trading rule. It supplies no market example or performance evidence, so the script is a visualization aid rather than a demonstrated strategy.

Key ideas

  • The script calculates and plots autocorrelation and partial autocorrelation across selected lags.
  • Inputs set the observation window, lag count, data offset, and chart display duration.
  • The plotted functions can help inspect serial dependence in financial data.
  • The document gives no trading application, statistical guidance, or performance evidence.

Tags

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