Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
plotlyで動くグラフを作る
Search
takuma koshiishi
January 21, 2023
Technology
0
1.1k
plotlyで動くグラフを作る
takuma koshiishi
January 21, 2023
Tweet
Share
More Decks by takuma koshiishi
See All by takuma koshiishi
R package for a team
kosshi
2
2.1k
Other Decks in Technology
See All in Technology
複雑な構成要素を持つUIとの向き合い方 〜新・支出グラフでの実例〜 / B43 TECH TALK
nakamuuu
0
100
SIEMを用いて、セキュリティログ分析の可視化と分析を実現し、PDCAサイクルを回してみた
coconala_engineer
0
220
開発生産性向上サービスを作るFindyが自分たちで開発生産性を爆上げした組織づくりの歩み / Findy's path to boosting its own development productivity 2024-04-17
ma3tk
3
340
Databricks における 『MLOps』
databricksjapan
2
140
Next'24 事例セッションの紹介とクラウド資格を活用したキャリア形成について語りMuscle
yasumuusan
1
340
カオナビの利用実績をアウトカムへつなげる旅 / example-of-data-management-startup-in-kaonavi
kaonavi
0
120
アプリがつくるNOT A HOTELブランド
hokuts
1
450
Postman v10リリース後を振り返る
nagix
0
130
4年前、あるじゃん老害エンジニアLT合戦に登壇、米国西海岸コンピュータ歴史博物館体験記の続編
toshi_atsumi
0
200
オブザーバビリティの Primary Signals
onk
PRO
0
550
o11y入門_外形監視を利用したWebアプリケーションへの最適なモニタリング_TechBrew
k5k
3
100
PHPカンファレンス小田原2024
ysknsid25
3
660
Featured
See All Featured
Building a Modern Day E-commerce SEO Strategy
aleyda
16
6.4k
Why You Should Never Use an ORM
jnunemaker
PRO
50
8.6k
RailsConf 2023
tenderlove
2
530
The MySQL Ecosystem @ GitHub 2015
samlambert
242
12k
In The Pink: A Labor of Love
frogandcode
138
21k
Rebuilding a faster, lazier Slack
samanthasiow
72
8.2k
The Invisible Side of Design
smashingmag
294
49k
Rails Girls Zürich Keynote
gr2m
91
13k
Art, The Web, and Tiny UX
lynnandtonic
288
19k
The Art of Programming - Codeland 2020
erikaheidi
41
12k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
226
16k
Side Projects
sachag
451
41k
Transcript
plotlyで 動くグラフを作る Takuma Koshiishi @kotaku08 Tokyo.R #103 2023/1/21
⾃⼰紹介 2 はじめまして こっしー 株式会社ヴァリューズ/データアナリスト @kotaku08 @kosshi • 4年ぶりのTokyo.R •
今も会社でR推進してる • plotly×shiny本の翻訳に参加
今⽇の⽬的 3 plotly触ってみようかな!と思ってもらう
Plotly 4 • ⼤元はJavascriptのデータ可視化ライブラリ(plotly.js) • インタラクティブに操作可能なぐるぐる動くグラフが描画で きる • Rのploltyパッケージなど、他⾔語から利⽤するクライアント が⽤意されている
← 今⽇plotlyと⾔ったらこのRパッケージ • データアナリストにとっては探索的データ分析とコミュニ ケーション(ダッシュボード作成など)に有益
Plotlyでダッシュボード 5 https://plotly-r.com/linking-views-with-shiny.html
ここを推したいPlotly 6 • とにかく動く!楽しい • 多様な出⼒形式。HTML、SVG、PDFなどで保存可能。 Rmarkdown、shinyとも連携できる。 • ggplot2と連携できて、初めの⼀歩の敷居が低い。今⽇か ら使える!
2つのグラフの描画⽅法① 7 ①ggplot2を利⽤して描画 ◦ggplot2のグラフをggplotly()に渡すだけ で簡単! ◦複雑なことでもggplot2とその拡張パッ ケージに任せられるのが嬉しい! ×対応してないgeomもある。
2つのグラフの描画⽅法② 8 ②plotlyの記法で描画 ◦plotlyパッケージ独⾃の書き⽅だが、 ggplot2の書き⽅が⼟台にあり、Rユーザに 優しい。 ◦インタラクティブな点のカスタマイズ性 に優れる。習熟するならこっち。
まとめ 9 • plotlyパッケージで動くグラフが作れるよ! • ggplot2と直接連携しているし、⽂法も似ているので ggplot2ユーザは簡単に始められるよ! • ⼀歩踏み出したらインタラクティブ性を極める旅に出かけ よう!(グラフ同⼠の連携やshinyアプリ作成など)
Enjoy! 10 仕事でR使いたい⼈募集しています! 興味がある⽅是⾮DMください!
参考⽂献 11 • 「Interactive web-based data visualization with R, plotly,
and shiny」https://plotly-r.com/index.html • 「Rによるインタラクティブなデータビジュアライゼー ション: 探索的データ解析のためのplotlyとshiny」