python pyecharts 库 数据可视化

本文介绍了如何使用Python的pyecharts库进行数据可视化,包括安装库、地图测试等步骤,适合Python初学者和数据可视化爱好者。
摘要由CSDN通过智能技术生成

本文参考自python pyecharts 库 数据可视化

查看原文: 原文地址

python pyecharts 库 数据可视化

作者微信公众号:小卫星

 操作系统: Windows 10

IDE: PyCharm Community 2018.1 

 Python 3.7

1、安装

$ pip install pyecharts

或者源码安装:

$ git clone https://github.com/pyecharts/pyecharts.git
$ cd pyecharts
$ pip install -r requirements.txt
$ python setup.py install

安装地图:

$ pip install echarts-countries-pypkg
$ pip install echarts-china-provinces-pypkg
$ pip install echarts-china-cities-pypkg
$ pip install echarts-china-counties-pypkg
$ pip install echarts-china-misc-pypkg
$ pip install echarts-united-kingdom-pypkg

2、测试

import random
from pyecharts import Polar, Page, Style
import math
#from app.charts.constants import WIDTH, HEIGHT

WIDTH = 600
HEIGHT = 400
def create_charts():
    page = Page()

    style = Style(width=WIDTH, height=HEIGHT)

    data = []
    for i in range(361):
        t = i / 180 * math.pi
        r = math.sin(<
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值