尝试在 Rstudio 中使用plotl_ly(),但它拒绝按预期在查看器窗格中渲染。
尝试卸载plotly、R和Rstudio,问题仍然存在。还有人有同样的问题吗?
尝试运行一个像这样的最小示例,我在查看器窗格中看到一个白色屏幕而不是绘图。
library(plotly)
plot_ly(x = 1:10, y = 1:10)
这是我的会话信息:
R version 4.4.0 (2024-04-24 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 11 x64 (build 22631)
Matrix products: default
locale:
[1] LC_COLLATE=English_Canada.utf8 LC_CTYPE=English_Canada.utf8 LC_MONETARY=English_Canada.utf8
[4] LC_NUMERIC=C LC_TIME=English_Canada.utf8
time zone: America/Toronto
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] plotly_4.10.4 ggplot2_3.5.1
loaded via a namespace (and not attached):
[1] vctrs_0.6.5 httr_1.4.7 cli_3.6.2 rlang_1.1.3 purrr_1.0.2
[6] generics_0.1.3 jsonlite_1.8.8 data.table_1.15.4 glue_1.7.0 colorspace_2.1-0
[11] htmltools_0.5.8.1 scales_1.3.0 fansi_1.0.6 grid_4.4.0 crosstalk_1.2.1
[16] munsell_0.5.1 tibble_3.2.1 fastmap_1.1.1 yaml_2.3.8 lifecycle_1.0.4
[21] compiler_4.4.0 dplyr_1.1.4 htmlwidgets_1.6.4 pkgconfig_2.0.3 tidyr_1.3.1
[26] rstudioapi_0.16.0 digest_0.6.35 viridisLite_0.4.2 R6_2.5.1 tidyselect_1.2.1
[31] utf8_1.2.4 pillar_1.9.0 magrittr_2.0.3 withr_3.0.0 tools_4.4.0
[36] gtable_0.3.5 lazyeval_0.2.2