Question Details

No question body available.

Tags

python excel

Answers (1)

Accepted Answer Available
Accepted Answer
June 3, 2025 Score: 0 Rep: 21 Quality: Medium Completeness: 40%

There was no misalignment, only a visual appearance of one.

The labels were centered, but looks to be aligned on the next tick's over quite well, thus giving the impression it was offset.

Fixing the xticks alignment ha to 'right' fixed the issue.

plt.xticks(rotation=45, ha='right')