Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Bug]: Subplot title does not obey padding #21394

Closed
@cipriantrofin

Description

@cipriantrofin

Bug summary

Last subplot title does not obey padding.

Code for reproduction

importpandasaspdimportmatplotlib.pyplotaspltdf=pd.DataFrame({"Austria" : [1,2,3,4,5],"Belgium" : [6,7,8,9,10],"France" : [11,12,13,14,15] },index=pd.to_datetime(['2000-01-01','2000-01-02','2000-01-03','2000-01-04','2000-01-05']))countryList=df.columnsfig,axs=plt.subplots(len(countryList),1,figsize= (15,len(countryList)*5),sharex=True)fori,cinenumerate(countryList):axs[i].bar(df.index,df[c])axs[i].set_title(c,pad=-14)

Actual outcome

subplots

Expected outcome

"France" subplot title should be aligned as the previous ones.

Operating system

Windows 10 x64

Matplotlib Version

3.4.3

Matplotlib Backend

module://matplotlib_inline.backend_inline

Python version

Python 3.8.5

Jupyter version

jupyter notebook v6.4.5

Other libraries

No response

Installation

pip

Conda channel

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp