How to change fonts in matplotlib (python)?

后端 未结 5 1124
不思量自难忘°
不思量自难忘° 2020-11-29 20:26

It sounds as an easy problem but I do not find any effective solution to change the font (not the font size) in a plot made with matplotlib in python.

I found a coup

5条回答
  •  有刺的猬
    2020-11-29 20:33

    import pylab as plb
    plb.rcParams['font.size'] = 12
    

    or

    import matplotlib.pyplot as mpl
    mpl.rcParams['font.size'] = 12
    

提交回复
热议问题