I am trying to plot simple moving averages (SMA) using Apple's stock price. I have lines below:

```
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.dates as mdates
import seaborn as sns

sns.set(style='darkgrid', context='talk', palette='Dark2')

my_year_month_fmt = mdates.DateFormatter('%m/%y')

data = pd.read_csv('C:\\AAPL.csv')

# tried to change the Date format, then its 'start_date' and 'end_date' but it doesn't work 
# data['Date'] = pd.to_datetime(data['Date'])

short_rolling = data.rolling(window=20).mean()
long_rolling = data.rolling(window=100).mean()

start_date = '1/4/2010'
end_date = '12/31/2019'

fig, ax = plt.subplots(figsize=(16,9))

ax.plot(data.loc[start_date:end_date, :].index, data.loc[start_date:end_date, 'Close'], label='Price')
ax.plot(long_rolling.loc[start_date:end_date, :].index, long_rolling.loc[start_date:end_date, 'Close'], label = '100-days SMA')
ax.plot(short_rolling.loc[start_date:end_date, :].index, short_rolling.loc[start_date:end_date, 'Close'], label = '20-days SMA')

ax.legend(loc='best')
ax.set_ylabel('Price in $')
ax.xaxis.set_major_formatter(my_year_month_fmt)

plt.show()

```

But the plotting isn't successful.

[![enter image description here](https://i.stack.imgur.com/8y8ti.png)](https://i.stack.imgur.com/8y8ti.png)

What did I do wrong, and how I can correct it?

[![enter image description here](https://i.stack.imgur.com/28Ucq.png)](https://i.stack.imgur.com/28Ucq.png)