Created
August 9, 2020 21:18
-
-
Save pkgandhi/8e6001418933d5bd33be40a35da4beb8 to your computer and use it in GitHub Desktop.
Using OCSV test to determine if the series needs D
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Loading the packages | |
import pandas as pd | |
import pmdarima | |
# Loading the dataset: | |
data = pd.read_csv('../AirPassengers.csv') | |
data = data.rename(columns = {'#Passengers':'Passengers'}) | |
data = data.set_index('Month') | |
# Conducting OCSB test: | |
results = pmdarima.arima.OCSBTest(m=12).estimate_seasonal_differencing_term(data) | |
# Output | |
# >> 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment