pie labels/values aren't relayed in event_data()
未關閉
還沒有人認領這個 Issue。
bug
- 主要語言
- R
- 星號
- 2.7k
- 分支
- 641
- PR 合併指標
- 30 天內沒有已合併 PR
描述
At least the customdata workaround exists, but we should do a better job relaying more information (do we 'black-list' pt.data/pt._fullData and let everything else through)? https://codepen.io/cpsievert/pen/rNNZpVo
library(shiny)
ui <- fluidPage(
plotlyOutput("category"),
verbatimTextOutput("info")
)
server <- function(input, output) {
output$category <- renderPlotly({
sales %>%
count(category, wt = sales) %>%
plot_ly() %>%
add_pie(labels = ~category, values = ~n)
})
output$info <- renderPrint({
event_data("plotly_click")
})
}
shinyApp(ui, server)
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
從提供的 Shiny 範例和 event_data("plotly_click") 入口點開始,將圓餅圖輸出與 customdata 變通方案進行比較。確定應傳遞哪些圓餅圖標籤和值,以及現有的 pt.data 和 pt._fullData 處理是否會排除它們。完成的標準是範例的事件資料中出現預期欄位。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- javascript, r
- 領域
- data-visualization
- Issue 類型
- 缺陷
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 停滯
- 描述清晰度
- 需要釐清
- 新手友好度
- 35/100