我在熊猫库的自相关图上遇到了一个奇怪的错误。
from pandas.plotting import autocorrelation_plot
[... other stuff ...]
def autocorrelation(self,data):
# Plot the autocorrelation of the given data series
# The autocorr. plot shows the autocorrelation value of original data over all lagged sample (lag = 0, lag = 1,...)
# lag = [0 to N-1] where N = len(data) [example: len(data) = 1000 sample --> lag = [0,999]]
print("Preparing plot for autocorrelation...")
plt.figure(1)
plt.title('Autocorrelation')
autocorrelation_plot(data)
这就是我得到的:
您可以在左侧(y轴)上看到值的重叠。你知道为什么吗?
谢谢