encoding: utf-8
###################设置utf-8编码##############
import sys
reload(sys)
sys.setdefaultencoding(‘utf-8’)
####################导入包########
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
##########设置中文显示
from pylab import *
import pandas as pd
mpl.rcParams[‘font.sans-serif’] = [‘SimHei’]
font_size =11 # 字体大小
fig_size = (8, 6) # 图表大小
更新字体大小
mpl.rcParams[‘font.size’] = font_size