File tree 1 file changed +5
-13
lines changed
1 file changed +5
-13
lines changed Original file line number Diff line number Diff line change @@ -21,20 +21,12 @@ Plot `numpy.datetime64` values
21
21
As of Matplotlib 2.2, `numpy.datetime64 ` objects are handled the same way
22
22
as `datetime.datetime ` objects.
23
23
24
- If you prefer the pandas converters and locators, you can register their
25
- converter with the `matplotlib.units ` module::
26
-
27
- from pandas.tseries import converter as pdtc
28
- pdtc.register()
29
-
30
- If you only want to use the `pandas ` converter for `numpy.datetime64 ` values ::
31
-
32
- from pandas.tseries import converter as pdtc
33
- import matplotlib.units as munits
34
- import numpy as np
35
-
36
- munits.registry[np.datetime64] = pdtc.DatetimeConverter()
24
+ If you prefer the pandas converters and locators, you can register them. This
25
+ is done automatically when calling a pandas plot function and may be
26
+ unnecessary when using pandas instead of Matplotlib directly. ::
37
27
28
+ from pandas.plotting import register_matplotlib_converters
29
+ register_matplotlib_converters()
38
30
39
31
40
32
.. _howto-figure-empty :
You can’t perform that action at this time.
0 commit comments