pandas.plotting.
lag_plot
Lag plot for time series.
Matplotlib scatter method keyword arguments.
Examples
Lag plots are most commonly used to look for patterns in time series data.
Given the following time series
>>> np.random.seed(5) >>> x = np.cumsum(np.random.normal(loc=1, scale=5, size=50)) >>> s = pd.Series(x) >>> s.plot()
A lag plot with lag=1 returns
lag=1
>>> pd.plotting.lag_plot(s, lag=1)