Add more bar tests
オープン
まだ誰も着手していません。
ggplotly
- 主要言語
- R
- スター
- 2.7k
- フォーク
- 641
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Just making a note so I don't forget -- add more tests for 71e29b4
# https://github.com/ropensci/plotly/issues/831
df <- data.frame(
V1 = gl(6,20), V2 = gl(40,3)
)
p <- ggplot(df, aes(x = V1, fill = V2)) + geom_bar(color="white")
ggplotly(p)
# https://github.com/ropensci/plotly/issues/560
d <- data.frame(
x = LETTERS[1:10],
y = -5:4,
g = rep(c('A','B'), each = 5)
)
p <- ggplot(data = d, aes(x = x, y = y, fill = g)) +
geom_bar(stat='identity')
ggplotly(p)
# https://github.com/ropensci/plotly/issues/901
data_before <- data.frame(
year = c(2014,2014,2014,2015,2015,2015,2016,2016,2016),
pet = c("dog","cat","bird","dog","cat","bird","dog","cat","bird"),
wt = c(56, 25, 26, 10, 19, 41, 16, 17, 13)
)
data_after <- data.frame(
year = c(2014,2014,2014,2015,2015,2015,2016,2016,2016),
pet = c("dog","cat","bird","dog","cat","bird","dog","cat","bird"),
wt = c(49, 18, 19, 3, 12, 34, 9, 10, 6)
)
p <- ggplot() +
geom_bar(data = data_before, aes(year, wt, fill = pet),
stat = "identity", position = "dodge", width = 0.9, alpha = 0.5) +
geom_bar(data = data_after, aes(year, wt, fill = pet),
stat = "identity", position = "dodge", width = 0.9) +
labs(x = "Year", y = "Weight") +
ggplotly(p)
# https://github.com/ropensci/plotly/issues/874
dd <- data.frame(x = rnorm(100,5,2))
dd2 <- data.frame(x = rnorm(100,5,2))
p3 <- ggplot() +
geom_histogram(data = dd,aes(x = x,y = ..count..)) +
geom_histogram(data = dd2,aes(x = x,y = -..count..),color = 'green')
ggplotly(p3)
# https://github.com/ropensci/plotly/issues/968
p <- ggplot(data=dat, aes(x=time, y=total_bill)) +
geom_bar(stat="identity") + coord_flip()
ggplotly(p)
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
テストファイルもエントリーポイントも指定されていません。まず既存の ggplotly の棒グラフとヒストグラムのテストを見つけ、次に issue 831、560、901、874、968 にリンクされた再現例を確認します。各ケースに回帰テストのカバレッジがあり、期待されるプロットの動作が記録されていれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- r
- 領域
- data-visualization, testing
- issue の種類
- リファクタリング
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 32/100