Skip to content

In depth introduction to time series forecasting covering a broad range of models.

License

Notifications You must be signed in to change notification settings

Py-Fi-nance/Introduction-to-Time-Series-Forecasting

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction-to-Time-Series-Forecasting

In depth introduction to time series forecasting covering a broad range of models. This notebook provides an example of time series analysis on NASDAQ daily closing prices. It includes data loading, visualization, handling missing values, decomposition, hyperparameter tuning for different moving averages, ARIMA modeling, and various statistical diagnostic tests.

Python Version

License: MIT

Forks Stars

Table of Contents

  1. Installation
  2. Data Loading
  3. Data Visualization
  4. Handling Missing Values
  5. Time Series Decomposition
  6. Moving Averages
  7. Autocorrelation and Partial Autocorrelation
  8. Stationarity Tests
  9. ARIMA Modeling
  10. Model Diagnostics
  11. Contributing
  12. Contact Information

Installation

!pip install openbb pandas numpy matplotlib statsmodels scikit-learn

Data Loading

from openbb_terminal.sdk import openbb
df_daily = openbb.stocks.load(symbol = 'ndaq')

Data Visualization

Plots for NASDAQ daily closing prices, trend, seasonal, and residual components.

Handling Missing Values

Code to identify and handle missing values in the dataset.

Time Series Decomposition

Decomposing the time series into observed, trend, seasonal, and residual components.

Moving Averages

Implementation and evaluation of Simple Moving Average (SMA) and Exponential Weighted Moving Average (EWMA) with hyperparameter tuning.

Autocorrelation and Partial Autocorrelation

Visualizing and interpreting the autocorrelation and partial autocorrelation functions.

Stationarity Tests

Includes Dickey-Fuller tests and differencing to achieve stationarity.

ARIMA Modeling

ARIMA modeling includes the process of identifying the best-fitting ARIMA model for the time series and making predictions.

Model Diagnostics

Residual analysis including ACF and PACF of residuals and squared residuals, Ljung-Box test, Kolmogorov-Smirnov test. Includes Goldfeld-Quandt test to identify any heteroskedasticity in the residuals.

Contributing

We welcome contributions to this project. To contribute:

  1. Fork the project.
  2. Create your feature branch (git checkout -b feature/AmazingFeature).
  3. Commit your changes (git commit -m 'Add some AmazingFeature').
  4. Push to the branch (git push origin feature/AmazingFeature).
  5. Open a Pull Request.

Contact Information

For any questions or inquiries, please contact support@pyfi.com - Subject: Github Repo Q, Introduction-to-Time-Series-Forecasting. For a full article walkthrough please visit > https://www.pyfi.com/blog/Introduction-to-Time-Series-Forecasting < and learn more about PyFi's award winning Python for Finance courses which have been trusted by the top financial institutions in the United States and Canada multiple years running here >> https://www.pyfi.com << Follow on LinkedIn

About

In depth introduction to time series forecasting covering a broad range of models.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published