Naren Castellon
07/21/2023, 3:54 PMimport pandas as pd
import matplotlib.pyplot as plt
from statsmodels.tsa.api import ExponentialSmoothing
# Import the data
#df = pd.read_csv("<https://raw.githubusercontent.com/Naren8520/Time-Series-with-Machine-Learning/main/Data/ads.csv>")
# Calculate the exponentially smoothed data
esm = ExponentialSmoothing(df['y'] )
esm_fit = esm.fit()
# Plot the data and the exponentially smoothed data
plt.plot(df['y'])
plt.plot(esm_fit.fittedvalues)
plt.title('Exponential Smoothing')
plt.xlabel('Time')
plt.ylabel('Value')
plt.show()
Can I use this same Statsmodel idea with StatsForecast?Monica Scott
07/21/2023, 6:19 PMNaren Castellon
07/21/2023, 6:27 PMMonica Scott
07/21/2023, 6:57 PMNaren Castellon
07/21/2023, 7:07 PMMonica Scott
07/21/2023, 7:16 PM