推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
julf
V2EX  ›  Python

请教关于 python 获取的 API 数据如何数据可视化?

  •  
  •   julf · Dec 20, 2016 · 4507 views
    This topic created in 3607 days ago, the information mentioned may be changed or developed.
    新人刚在自学 python ,语法刚刷几遍,目前在尝试一些小项目。现在遇到一个问题,想实现从网站提供的 api 接口获取的数据,对其中部分数据实现数据可视化,从而能否监控其数据变动。想请老手指点一下学习及实现的路径,感激不尽。如下是获取的数据类型,主要是想统计每天的数据变化,并生成柱状图或者曲线图。

    [
    {
    "id": "bitcoin",
    "name": "Bitcoin",
    "symbol": "BTC",
    "rank": "1",
    "price_usd": "573.137",
    "price_btc": "1.0",
    "24h_volume_usd": "72855700.0",
    "market_cap_usd": "9080883500.0",
    "available_supply": "15844176.0",
    "total_supply": "15844176.0",
    "percent_change_1h": "0.04",
    "percent_change_24h": "-0.3",
    "percent_change_7d": "-0.57",
    "last_updated": "1472762067"
    },
    {
    "id": "ethereum",
    "name": "Ethereum",
    "symbol": "ETH",
    "rank": "2",
    "price_usd": "12.1844",
    "price_btc": "0.021262",
    "24h_volume_usd": "24085900.0",
    "market_cap_usd": "1018098455.0",
    "available_supply": "83557537.0",
    "total_supply": "83557537.0",
    "percent_change_1h": "-0.58",
    "percent_change_24h": "6.34",
    "percent_change_7d": "8.59",
    "last_updated": "1472762062"
    },
    ...
    ]
    9 replies  •  2016-12-21 15:30:03 +08:00
    UnisandK
    UnisandK
    Dec 20, 2016
    1
    有专门做数据可视化服务的
    http://blog.oneapm.com/apm-tech/321.html
    比如这个
    simon7
    simon7
    Dec 20, 2016 via iPad
    2
    bokeh
    stamaimer
    stamaimer
    Dec 20, 2016 via iPhone
    3
    d3.js
    namco1992
    namco1992
    Dec 20, 2016
    4
    plotly https://plot.ly/

    不过还是 c3.js 方便一点吧。
    316461465
    316461465
    Dec 20, 2016
    5
    原生 python 的话推荐你用 Matplotlib ,如果是 web 的话,百度的 echarts 够你玩的了
    julf
    julf
    OP
    Dec 20, 2016
    6
    @316461465 , Matplotlib 是可以实现可视化,我从 API 获取的数据是否需要导入数据库保存及提取
    mingyun
    mingyun
    Dec 20, 2016
    7
    python highcharts
    dikT
    dikT
    Dec 21, 2016
    8
    from pprint import pprint
    pprint(data)
    dikT
    dikT
    Dec 21, 2016
    9
    晕,请无视.
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   5222 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 06:23 · PVG 14:23 · LAX 22:23 · JFK 01:23
    ♥ Do have faith in what you're doing.