Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Python pandas datetime plot xticks in unexpected location #12925

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
hagaishalev opened this issue Dec 3, 2018 · 2 comments
Closed

Python pandas datetime plot xticks in unexpected location #12925

hagaishalev opened this issue Dec 3, 2018 · 2 comments

Comments

@hagaishalev
Copy link

Bug report

I wouldn't have expected to see the 29th of some of the month labelled
Bug summary
I wouldn't have expected to see the 29th of some of the month labelled

Code for reproduction

# Paste your code here
#
#
import pandas as pd
import matplotlib.pyplot as plt
x = pd.date_range(start='1/1/2018', periods=80) # 80 days
y = pd.np.random.random(80)
plt.plot(x, y ,'o')
plt.xticks(rotation='vertical')

Actual outcome
timeplot

# If applicable, paste the console output here
#
#

Expected outcome

Matplotlib version

  • Operating system: Win10 64bit
  • Matplotlib version: 3.0.1
  • Matplotlib backend (print(matplotlib.get_backend())): module://ipykernel.pylab.backend_inline
  • Python version: 3.7.1
  • Jupyter version (if applicable): 5.7.2
  • Other libraries: pandas 0.23.4
  • conda 4.5.11
@jklymak
Copy link
Member

jklymak commented Dec 3, 2018

Yes agreed this is a strange choice. Fixed in #10841 which will hopefully be part of 3.1

@jklymak jklymak added this to the v3.1 milestone Dec 3, 2018
@jklymak
Copy link
Member

jklymak commented Feb 11, 2019

Master now no longer has the 29 ticks....

@jklymak jklymak closed this as completed Feb 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants