Autocorrelation

Ryan E. Emanuel, Joshua S. Rice, and Jasmine N. Gregory. North Carolina State University (ryan_emanuel@ncsu.edu)

Author Profile

Introduction

Correlation analysis is a standard tool used to understand how two variables change relative to one another. Autocorrelation is a form of correlation analysis can be used to understand how elements within the same time series are related to one another. In other words, autocorrelation considers the relationship between a dataset a lagged version of itself. The correlation at various lag times is represented by an autocorrelation function. Autocorrelation is an important concept in the analysis of time series, and visualizations of autocorrelation functions can provide quite a bit of useful information. This step will focus on exploring these concepts.

Conceptual Outcomes

1) Gain a conceptual understanding of autocorrelation.

Practical Outcomes

1) Use open source tools to quantify and visualize autocorrelation in example data series.

Time Required

1-2 hours, depending on comfort level with modifying small amounts of code (e.g., file paths) and depth of responses to questions.

Computing/Data Inputs

1) Provided example data
2) Provided example code

Computing/Data Outputs

1) Answers to various questions provided in the instructions.
2) Data visualizations created while working through the instructions.

Hardware/Software Required

An interactive python environment (iPython or jupyter) (all of which are included in the open source Anaconda distribution of python) with the Numpy, SciPy, matplotlib, and pandas libraries installed.

Instructions

Line by line instructions are found in the provided jupyter notebook: unit_1_step_2_notebook_new.ipynb ( 462kB Feb15 21)

See Additional Files:

neuse_streamflow.csv (Comma Separated Values 12kB Aug17 20)

neuse_precipitation.csv (Comma Separated Values 9kB Aug17 20)

mei_vec.csv (Comma Separated Values 9kB Aug17 20)

Additional Activities and Variants

The provided instructions and code can be adapted to any time series data that use the same format as the example files.

Related steps:
Other steps from this unit