`
dyx1024
  • 浏览: 114978 次
  • 性别: Icon_minigender_1
  • 来自: 西安
文章分类
社区版块
存档分类
最新评论

Python:使用pycha快速绘制办公常用图(饼图、垂直直方图、水平直方图、散点图等七种图形)

 
阅读更多

今天晚上学习了下使用pycha模块来制作各种办公用图的方法,非常简单,本文使用其绘制了7种图表。

此模块和API地址为:http://www.lorenzogil.com/projects/pycha/,需要的朋友可以下载下来玩一下,下面是我晚上学习时写的一点东东,分享之。


一、代码:


二、测试:

1、函数draw_pie(surface, options, dataSet):

2、函数draw_vertical_bar(surface, options, dataSet):

3、函数draw_horizontal_bar(surface, options, dataSet):

4、函数draw_line(surface, options, dataSet):

5、函数draw_scatterplot(surface, options, dataSet):

6、函数draw_stackedverticalbarChar(surface, options, dataSet):

7、函数draw_stackedhorizontalbarChart(surface, options, dataSet):



分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics