I have created 6 different dataframes that eliminate the outliers of their own original data frames. Now, I\'m trying to plot all of the dataframes that eliminate the outlie
Am I missing something? Normally, I just do this for multiple dataframes:
fig = plt.figure()
for frame in [newdf, newdf2, newdf3, newdf4, newdf5]:
plt.plot(frame['Time'], frame['Data'])
plt.xlim(0,18000)
plt.ylim(0,30)
plt.show()
You need to use the ax
parameter in pandas.dataframe.plot.
Use on the first df.plot to grab a handle on that axes:
ax = newdf.plot()
then on subsequent plots use the ax parameter.
newdf2.plot(ax=ax)
...
newdf5.plot(ax=ax)