【R】ggchartsで楽々Chart
2020年5月14日
ggcharts
というパッケージがCRANで公開になりました。ggplot
を使用した時とggchrts
を使用した時の比較がありますが、本当に楽々ですね!
試しに世界の平均余命の変遷をチャートで見てみました。

R
のコードは次の通り。本当に簡単!
library(dplyr)
library(ggplot2)
library(ggcharts)
library(gapminder)
dat<-gapminder
bar_chart(dat, country, lifeExp, facet = year, top_n = 10)