Return the `~datetime.tzinfo` instance of *x* or of its first element, or None
(x, axis)
| 1767 | |
| 1768 | @staticmethod |
| 1769 | def default_units(x, axis): |
| 1770 | """ |
| 1771 | Return the `~datetime.tzinfo` instance of *x* or of its first element, |
| 1772 | or None |
| 1773 | """ |
| 1774 | if isinstance(x, np.ndarray): |
| 1775 | x = x.ravel() |
| 1776 | |
| 1777 | try: |
| 1778 | x = cbook._safe_first_finite(x) |
| 1779 | except (TypeError, StopIteration): |
| 1780 | pass |
| 1781 | |
| 1782 | try: |
| 1783 | return x.tzinfo |
| 1784 | except AttributeError: |
| 1785 | pass |
| 1786 | return None |
| 1787 | |
| 1788 | |
| 1789 | class ConciseDateConverter(DateConverter): |
no outgoing calls
no test coverage detected