您的位置:首页 > 编程语言 > PHP开发

matplotlib(legend)

2017-07-18 10:53 417 查看
matplotlib legend的各个参数的作用: 
bbox_to_anchor :
matplotlib.transforms.BboxBase
instance or tuple of floats(设置legend的在任意位置)
loc='upper right', bbox_to_anchor=(0.5, 0.5)

ncol : integer(每列legend的个数) 
prop:None or
matplotlib.font_manager.FontProperties
or dict(设置legend的字体属性)
 
fontsize:字体大小 
numpoints : None or int 
shadow : None or bool(控制阴影) 
framealpha : None or float(控制legend背景的透明度) 
facecolor : None or “inherit” or a color spec(控制legend的背景颜色) 
edgecolor : None or “inherit” or a color spec(控制legend背景的边界颜色) 
mode : {“expand”, None}('expand'的话会让legend和坐标轴一样长) 
title : str or None(legend的标题,注意只有一个t) 
borderpad : float or None(legend周围空白的多少) 
labelspacing : float or None(legend之间的垂直距离)

 
handlelength : float or None(legend的句柄的长短,指的是文字前面图的长短) 
handletextpad : float or None(句柄和文字之间的距离) 
borderaxespad : float or None(legend与坐标轴之间的距离) 
columnspacing : float or None(每列之间的距离) 
  
  
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: