{ "cells": [ { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "# Pythonによるインタラクティブ可視化入門\n", "\n", "- [みんなのPython勉強会#61](https://startpython.connpass.com/event/186016/)\n", "- 2020-09-10\n", "- driller[@patraqushe](https://twitter.com/patraqushe)" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### 誰?\n", "\n", "- [どりらん](https://twitter.com/patraqushe)\n", "- [fin-py](https://fin-py.connpass.com)\n", "- ぼっち会社経営\n", " - 在宅勤務歴10年\n", " - 非エンジニア" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### fin-py\n", "\n", "Python × 金融のコミュニティ\n", "\n", "![](https://github.com/fin-py/logo/blob/master/finpy_200x200.png?raw=true)\n", "\n", "#### [fin-pyもくもく会 #36](https://fin-py.connpass.com/event/186842/)\n", "\n", "https://fin-py.connpass.com/event/186842/\n", "\n", "- オンライン(Discord)のもくもく会\n", "- 2020/09/12(土) 10:00 〜 13:00\n", "- 特別企画あり" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### Pythonによる株価分析ハンズオン\n", "\n", "https://quantopian-tokyo.connpass.com/event/187549/\n", "\n", "- オンライン(Google Meet)のハンズオン\n", "- 2020/09/20(日) 13:00 〜 17:00\n", "- Python, Numpy, pandasの基礎から統計の基礎まで\n", "\n", "![](https://connpass-tokyo.s3.amazonaws.com/thumbs/76/2a/762a8192223aeb6d410c21669324b1c5.png)" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### Software Design 2020年10月号に寄稿しました\n", "\n", "- 第1特集 コードで実践,ビジュアルで納得 Pythonではじめる統計学\n", "- Pythonの基礎文法は知ってるけど統計を一から学びたい人にオススメ\n", "\n", "[![](https://gihyo.jp/assets/images/cover/2020/thumb/TH160_642010.jpg)](https://gihyo.jp/magazine/SD/archive/2020/202010)" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### バックナンバーもよろしくネ\n", "\n", "2018年2月号|SD別冊シリーズ|2019年4月号|2020年2月号\n", "---|---|---|---\n", "[![](https://gihyo.jp/assets/images/cover/2018/thumb/TH160_641802.jpg)](https://gihyo.jp/magazine/SD/archive/2018/201802)|[![](https://gihyo.jp/assets/images/cover/2019/thumb/TH160_9784297103965.jpg)](https://gihyo.jp/book/2019/978-4-297-10396-5)|[![](https://gihyo.jp/assets/images/cover/2019/thumb/TH160_641904.jpg)](https://gihyo.jp/magazine/SD/archive/2019/201904)|[![](https://gihyo.jp/assets/images/cover/2020/thumb/TH160_642002.jpg)](https://gihyo.jp/magazine/SD/archive/2020/202002)" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "### Pythonの可視化ライブラリ\n", "\n", "![Python Visualization Landscape](https://github.com/rougier/python-visualization-landscape/raw/master/landscape-colors.png)\n", "\n", "> [Python Visualization Landscape](https://github.com/rougier/python-visualization-landscape) より引用" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### 大きくわけて2つに分類される\n", "\n", "- 静的画像による描画\n", " - Matplotlib\n", " - seaborn\n", "- 動的な描画(JavaScriptなど)\n", " - Bokeh\n", " - plotly" ] }, { "cell_type": "markdown", "metadata": { "slideshow": { "slide_type": "subslide" } }, "source": [ "### gapminderデータセット\n", "\n", "https://www.gapminder.org/\n", "\n", "列名|説明\n", "---|---\n", "country|国名\n", "continent|大陸名\n", "year|年度\n", "lifeExp|寿命\n", "pop|人口\n", "gdpPercap|人口当りGDP" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "hideCode": false, "hidePrompt": false, "slideshow": { "slide_type": "fragment" } }, "outputs": [ { "data": { "text/html": [ "
\n", " | country | \n", "continent | \n", "year | \n", "lifeExp | \n", "pop | \n", "gdpPercap | \n", "iso_alpha | \n", "iso_num | \n", "
---|---|---|---|---|---|---|---|---|
0 | \n", "Afghanistan | \n", "Asia | \n", "1952 | \n", "28.801 | \n", "8425333 | \n", "779.445314 | \n", "AFG | \n", "4 | \n", "
1 | \n", "Afghanistan | \n", "Asia | \n", "1957 | \n", "30.332 | \n", "9240934 | \n", "820.853030 | \n", "AFG | \n", "4 | \n", "
2 | \n", "Afghanistan | \n", "Asia | \n", "1962 | \n", "31.997 | \n", "10267083 | \n", "853.100710 | \n", "AFG | \n", "4 | \n", "
3 | \n", "Afghanistan | \n", "Asia | \n", "1967 | \n", "34.020 | \n", "11537966 | \n", "836.197138 | \n", "AFG | \n", "4 | \n", "
4 | \n", "Afghanistan | \n", "Asia | \n", "1972 | \n", "36.088 | \n", "13079460 | \n", "739.981106 | \n", "AFG | \n", "4 | \n", "