@@ -123,6 +123,22 @@ def scatter_matrix(
123
123
124
124
>>> df = pd.DataFrame(np.random.randn(1000, 4), columns=['A','B','C','D'])
125
125
>>> pd.plotting.scatter_matrix(df, alpha=0.2)
126
+ array([[<AxesSubplot:xlabel='A', ylabel='A'>,
127
+ <AxesSubplot:xlabel='B', ylabel='A'>,
128
+ <AxesSubplot:xlabel='C', ylabel='A'>,
129
+ <AxesSubplot:xlabel='D', ylabel='A'>],
130
+ [<AxesSubplot:xlabel='A', ylabel='B'>,
131
+ <AxesSubplot:xlabel='B', ylabel='B'>,
132
+ <AxesSubplot:xlabel='C', ylabel='B'>,
133
+ <AxesSubplot:xlabel='D', ylabel='B'>],
134
+ [<AxesSubplot:xlabel='A', ylabel='C'>,
135
+ <AxesSubplot:xlabel='B', ylabel='C'>,
136
+ <AxesSubplot:xlabel='C', ylabel='C'>,
137
+ <AxesSubplot:xlabel='D', ylabel='C'>],
138
+ [<AxesSubplot:xlabel='A', ylabel='D'>,
139
+ <AxesSubplot:xlabel='B', ylabel='D'>,
140
+ <AxesSubplot:xlabel='C', ylabel='D'>,
141
+ <AxesSubplot:xlabel='D', ylabel='D'>]], dtype=object)
126
142
"""
127
143
plot_backend = _get_plot_backend ("matplotlib" )
128
144
return plot_backend .scatter_matrix (
@@ -208,6 +224,7 @@ def radviz(frame, class_column, ax=None, color=None, colormap=None, **kwds):
208
224
... }
209
225
... )
210
226
>>> pd.plotting.radviz(df, 'Category')
227
+ <AxesSubplot:xlabel='y(t)', ylabel='y(t + 1)'>
211
228
"""
212
229
plot_backend = _get_plot_backend ("matplotlib" )
213
230
return plot_backend .radviz (
@@ -266,6 +283,7 @@ def andrews_curves(
266
283
... 'pandas/master/pandas/tests/io/data/csv/iris.csv'
267
284
... )
268
285
>>> pd.plotting.andrews_curves(df, 'Name')
286
+ <AxesSubplot:title={'center':'width'}>
269
287
"""
270
288
plot_backend = _get_plot_backend ("matplotlib" )
271
289
return plot_backend .andrews_curves (
@@ -325,6 +343,7 @@ def bootstrap_plot(series, fig=None, size=50, samples=500, **kwds):
325
343
326
344
>>> s = pd.Series(np.random.uniform(size=100))
327
345
>>> pd.plotting.bootstrap_plot(s)
346
+ <Figure size 640x480 with 6 Axes>
328
347
"""
329
348
plot_backend = _get_plot_backend ("matplotlib" )
330
349
return plot_backend .bootstrap_plot (
@@ -392,6 +411,7 @@ def parallel_coordinates(
392
411
>>> pd.plotting.parallel_coordinates(
393
412
... df, 'Name', color=('#556270', '#4ECDC4', '#C7F464')
394
413
... )
414
+ <AxesSubplot:xlabel='y(t)', ylabel='y(t + 1)'>
395
415
"""
396
416
plot_backend = _get_plot_backend ("matplotlib" )
397
417
return plot_backend .parallel_coordinates (
@@ -440,13 +460,15 @@ def lag_plot(series, lag=1, ax=None, **kwds):
440
460
>>> x = np.cumsum(np.random.normal(loc=1, scale=5, size=50))
441
461
>>> s = pd.Series(x)
442
462
>>> s.plot()
463
+ <AxesSubplot:xlabel='Midrange'>
443
464
444
465
A lag plot with ``lag=1`` returns
445
466
446
467
.. plot::
447
468
:context: close-figs
448
469
449
470
>>> pd.plotting.lag_plot(s, lag=1)
471
+ <AxesSubplot:xlabel='y(t)', ylabel='y(t + 1)'>
450
472
"""
451
473
plot_backend = _get_plot_backend ("matplotlib" )
452
474
return plot_backend .lag_plot (series = series , lag = lag , ax = ax , ** kwds )
@@ -480,6 +502,7 @@ def autocorrelation_plot(series, ax=None, **kwargs):
480
502
>>> spacing = np.linspace(-9 * np.pi, 9 * np.pi, num=1000)
481
503
>>> s = pd.Series(0.7 * np.random.rand(1000) + 0.3 * np.sin(spacing))
482
504
>>> pd.plotting.autocorrelation_plot(s)
505
+ <AxesSubplot:title={'center':'width'}, xlabel='Lag', ylabel='Autocorrelation'>
483
506
"""
484
507
plot_backend = _get_plot_backend ("matplotlib" )
485
508
return plot_backend .autocorrelation_plot (series = series , ax = ax , ** kwargs )
0 commit comments