Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 27aaf0c commit 9746040Copy full SHA for 9746040
1 file changed
lib/matplotlib/dates.py
@@ -802,6 +802,9 @@ def format_ticks(self, values):
802
# 3: hours, 4: minutes, 5: seconds, 6: microseconds
803
for level in range(5, -1, -1):
804
if len(np.unique(tickdate[:, level])) > 1:
805
+ # if level is less than 2, a year is already present in the axis
806
+ if (level < 2):
807
+ self.show_offset = False
808
break
809
elif level == 0:
810
# all tickdate are the same, so only micros might be different
0 commit comments