-
Notifications
You must be signed in to change notification settings - Fork 36
save_iheatmap rendering blank output #111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I wasn't able to reproduce this yet, I'll revisit tomorrow |
I have the same issue on a different system and version of R, although the version of iheatmapr is slightly different R version 3.6.0 (2019-04-26) Matrix products: default locale: attached base packages: other attached packages: loaded via a namespace (and not attached): |
I wouldn't expect it to work on R 3.6.0. Can you try to save a heatmap using eg: htmlwidgets::saveWidget(iheatmapr::to_widget(iheatmap(matrix(rnorm(100), 10, 10))), "tmp.html") then open the file in your favourite browser and check for any console errors in the browser devtools? |
I'm able to save the heatmap and it renders in the html file with no errors/no messages in the console. |
Oh dear, that's ironically the worst outcome when it comes to debugging. I'll try a different rstudio setup as soon as I can. Can you check if it works from a regular r session, outside of rstudio? It should pop up your default browser, you can check for console output if it doesn't work |
Unfortunately same issue. It can render in a regular R session and I see it pop-up in the browser, it can render the html, but the png output is still blank with save_iheatmap(). I had to add pandoc to my Windows PATH environment since I was seeing this error when I tried to export the image, but it didn't help rendering the png output. |
Hang on, so when you say
Do you mean viewing a dynamic plot, or a static image? |
The dynamic plot. My goal is to have a dynamic plot in the html and save a static version to a png to use in presentations, etc. Exporting the dynamic plot in an html has worked for me, unless I'm in an interactive session and the plot tries to display in the Viewer window rather than the main coding window (i.e. working in an RMarkdown where the plot may display below the coding chunk). I mentioned it in case the dynamic plot not displaying in the Viewer window was related to not being able to save a static version to a png. |
Hmm, so we have:
Am I right? I can reproduce the blank PNG now, so should be able to look into this soon. Incidentally I ran into this on Linux. Still can't reproduce the RStudio problem. Are you running a reasonably recent RStudio version? |
That's correct! Regarding Linux, I did add Sys.setenv(OPENSSL_CONF="/dev/null") to my .Rprofile to get the html graphics to generate. |
Uh oh!
There was an error while loading. Please reload this page.
Hi, I am able to render the example heatmap in an RMarkdown html export, but when I try to use save_iheatmap() or try to render the heatmap in the RStudio Viewer, the result is a blank image. Thanks for any help!
`
mat <- matrix(rnorm(24), nrow = 6)
hm <- iheatmap(mat)
save_iheatmap(hm, "example_iheatmap.png")
hm
`
R version 4.4.0 (2024-04-24 ucrt)
Platform: x86_64-w64-mingw32/x64
Running under: Windows 10 x64 (build 19045)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.utf8
[2] LC_CTYPE=English_United States.utf8
[3] LC_MONETARY=English_United States.utf8
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.utf8
time zone: America/New_York
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] iheatmapr_0.7.1
loaded via a namespace (and not attached):
[1] cli_3.6.2 knitr_1.48 rlang_1.1.3 xfun_0.44
[5] processx_3.8.4 jsonlite_1.8.8 glue_1.7.0 colorspace_2.1-0
[9] htmltools_0.5.8.1 ps_1.7.6 fastcluster_1.2.6 sass_0.4.9
[13] scales_1.3.0 rmarkdown_2.28 evaluate_1.0.0 munsell_0.5.1
[17] jquerylib_0.1.4 fastmap_1.2.0 yaml_2.3.8 lifecycle_1.0.4
[21] compiler_4.4.0 RColorBrewer_1.1-3 htmlwidgets_1.6.4 rstudioapi_0.16.0
[25] farver_2.1.2 digest_0.6.35 R6_2.5.1 callr_3.7.6
[29] magrittr_2.0.3 bslib_0.8.0 webshot_0.5.5 tools_4.4.0
[33] cachem_1.1.0
The text was updated successfully, but these errors were encountered: