admin に投稿
Windows

フォント インストール


🔗 Google Fonts

・Noto Sans Japanese
・Noto Serif Japanese

Image
google font

 

展開すると「static」フォルダがある。開いて全部選んで右クリック。

インストール。

設定

ホームディレクトリにフォルダ「.matplotlib」を作る。
・anaconda
「anaconda3/Lib/site-packages/matplotlib/mpl-data/matplotlibrc」を「.matplotlib」内にコピー。

【matplotlibrc】

## ***************************************************************************
## * FONT                                                                    *       
## ***************************************************************************
<省略>
font.serif : Noto Serif JP
font.sans-serif : Noto Sans JP
## ***************************************************************************
## * TEXT                                                                    *
## ***************************************************************************

Visual Studio Code

 

インタープリターの選択

Image
VScode

 

テスト

import matplotlib.pyplot as plt

plt.title("今日はいい天気!")
plt.show()

 

Image
matplotlib