ARIMA-modellen in Python
James Fulton
Climate informatics researcher





tijdreeks = trend + seizoen + residu
# Import
from statsmodels.tsa.seasonal import seasonal_decompose
# Decompose data
decomp_results = seasonal_decompose(df['IPG3113N'], period=12)
type(decomp_results)
statsmodels.tsa.seasonal.DecomposeResult
# Plot decomposed data
decomp_results.plot()
plt.show()



# Trek lang voortschrijdend gemiddelde over N stappen af df = df - df.rolling(N).mean()# Verwijder NaN-waarden df = df.dropna()

# Maak figuur
fig, ax = plt.subplots(1,1, figsize=(8,4))
# Plot ACF
plot_acf(df.dropna(), ax=ax, lags=25, zero=False)
plt.show()


ARIMA-modellen in Python