8000 Update acorr and xcorr docs to match numpy · matplotlib/matplotlib@eb30608 · GitHub
[go: up one dir, main page]

Skip to content

Commit eb30608

Browse files
committed
Update acorr and xcorr docs to match numpy
1 parent b152acd commit eb30608

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/matplotlib/axes/_axes.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1885,7 +1885,7 @@ def acorr(self, x, **kwargs):
18851885
Notes
18861886
-----
18871887
The cross correlation is performed with :func:`numpy.correlate` with
1888-
``mode = 2``.
1888+
``mode = "full"``.
18891889
"""
18901890
return self.xcorr(x, x, **kwargs)
18911891

@@ -1946,7 +1946,7 @@ def xcorr(self, x, y, normed=True, detrend=mlab.detrend_none,
19461946
Notes
19471947
-----
19481948
The cross correlation is performed with :func:`numpy.correlate` with
1949-
``mode = 2``.
1949+
``mode = "full"``.
19501950
"""
19511951
Nx = len(x)
19521952
if Nx != len(y):
@@ -1955,7 +1955,7 @@ def xcorr(self, x, y, normed=True, detrend=mlab.detrend_none,
19551955
x = detrend(np.asarray(x))
19561956
y = detrend(np.asarray(y))
19571957

1958-
correls = np.correlate(x, y, mode=2)
1958+
correls = np.correlate(x, y, mode="full")
19591959

19601960
if normed:
19611961
correls /= np.sqrt(np.dot(x, x) * np.dot(y, y))

0 commit comments

Comments
 (0)
0