Provides a MATLAB-like plotting framework.
pylab
combines pyplot with numpy into a single namespace. This is convenient for interactive work, but for programming it is recommended that the namespaces be kept separate, e.g.:import numpy as np
import matplotlib.pyplot as plt
x = np.arange(0, 5, 0.1);
y = np.sin(x)
plt.plot(x, y)
matplotlib.pyplot.
acorr
(x, hold=None, data=None, **kwargs)- Plot the autocorrelation of
x
.Parameters: x : sequence of scalarhold : boolean, optional, deprecated, default: Truedetrend : callable, optional, default:mlab.detrend_none
x is detrended by thedetrend
callable. Default is no normalization.normed : boolean, optional, default: Trueif True, input vectors are normalised to unit length.usevlines : boolean, optional, default: Trueif True, Axes.vlines is used to plot the vertical lines from the origin to the acorr. Otherwise, Axes.plot is used.maxlags : integer, optional, default: 10number of lags to show. If None, will return all 2 * len(x) - 1 lags.Returns: (lags, c, line, b) : where:Other Parameters: linestyle :Line2D
prop, optional, default: NoneOnly used if usevlines is False.marker : string, optional, default: ‘o’NotesThe cross correlation is performed withnumpy.correlate()
withmode
= 2.Examples
No comments:
Post a Comment