talgalili / heatmaply

Interactive Heat Maps for R Using plotly
377 stars 73 forks source link

Move or remove dendrogram cluster annotations? #212

Closed givison closed 5 years ago

givison commented 5 years ago

Hi,

I'm running this code:

BrBG <- colorRampPalette(brewer.pal(11, "BrBG"))

heatmaply(normedNKFoldChange,
          main = "Arcsinh transformed fold-change over unstimulated",
          ylab = "Timepoint",
          Rowv = FALSE,
          xlab = "Epitope",
          colors = BrBG,
          limits = c(-max(abs(normedNKFoldChange)), max(abs(normedNKFoldChange))),
          k_col = 5)

And I get this output (cropped to remove title and row and column labels)

image

I can't seem to figure out which arguments control the positioning of these line annotations in the upper right hand corner, and they are a bit unsightly with the colorbar half-covering them... Sorry if this is in the documentation and I'm missing it! Could you provide any clue as to how I could move them or remove them?

Here's my session info:

## R version 3.5.3 (2019-03-11)
## Platform: x86_64-apple-darwin15.6.0 (64-bit)
## Running under: macOS Mojave 10.14.5
## 
## Matrix products: default
## BLAS: /Library/Frameworks/R.framework/Versions/3.5/Resources/lib/libRblas.0.dylib
## LAPACK: /Library/Frameworks/R.framework/Versions/3.5/Resources/lib/libRlapack.dylib
## 
## locale:
## [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
## 
## attached base packages:
## [1] stats     graphics  grDevices utils     datasets  methods   base     
## 
## other attached packages:
##  [1] RColorBrewer_1.1-2 heatmaply_0.16.0   viridis_0.5.1     
##  [4] viridisLite_0.3.0  plotly_4.9.0       magrittr_1.5      
##  [7] forcats_0.4.0      stringr_1.4.0      dplyr_0.8.0.1     
## [10] purrr_0.3.2        readr_1.3.1        tidyr_0.8.3       
## [13] tibble_2.1.1       ggplot2_3.1.1      tidyverse_1.2.1   
## [16] beepr_1.3         
## 
## loaded via a namespace (and not attached):
##  [1] httr_1.4.0         jsonlite_1.6       foreach_1.4.4     
##  [4] modelr_0.1.4       gtools_3.8.1       shiny_1.3.2       
##  [7] assertthat_0.2.1   cellranger_1.1.0   yaml_2.2.0        
## [10] pillar_1.3.1       backports_1.1.4    lattice_0.20-38   
## [13] glue_1.3.1         digest_0.6.18      promises_1.0.1    
## [16] rvest_0.3.3        colorspace_1.4-1   httpuv_1.5.1      
## [19] htmltools_0.3.6    plyr_1.8.4         pkgconfig_2.0.2   
## [22] broom_0.5.2        haven_2.1.0        xtable_1.8-4      
## [25] scales_1.0.0       webshot_0.5.1      gdata_2.18.0      
## [28] later_0.8.0        generics_0.0.2     withr_2.1.2       
## [31] lazyeval_0.2.2     cli_1.1.0          mime_0.6          
## [34] crayon_1.3.4       readxl_1.3.1       evaluate_0.13     
## [37] nlme_3.1-139       MASS_7.3-51.4      gplots_3.0.1.1    
## [40] xml2_1.2.0         tools_3.5.3        registry_0.5-1    
## [43] data.table_1.12.2  hms_0.4.2          munsell_0.5.0     
## [46] cluster_2.0.9      compiler_3.5.3     caTools_1.17.1.2  
## [49] rlang_0.3.4        grid_3.5.3         iterators_1.0.10  
## [52] rstudioapi_0.10    htmlwidgets_1.3    crosstalk_1.0.0   
## [55] bitops_1.0-6       labeling_0.3       rmarkdown_1.12    
## [58] gtable_0.3.0       codetools_0.2-16   TSP_1.1-6         
## [61] reshape2_1.4.3     R6_2.4.0           seriation_1.2-7   
## [64] gridExtra_2.3      lubridate_1.7.4    knitr_1.22        
## [67] KernSmooth_2.23-15 dendextend_1.12.0  stringi_1.4.3     
## [70] Rcpp_1.0.1         gclus_1.3.2        audio_0.1-6       
## [73] tidyselect_0.2.5   xfun_0.6

Thanks!

alanocallaghan commented 5 years ago

Should be fixed now, @givison. Either install the current github version or try the same call to heatmaply with plot_method="plotly" rather than the default.

givison commented 5 years ago

Thanks!

On Tue, Jun 18, 2019 at 2:48 AM Alanocallaghan notifications@github.com wrote:

Should be fixed now, @givison https://github.com/givison. Either install the current github version or try the same call to heatmaply with plot_method="plotly" rather than the default.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/talgalili/heatmaply/issues/212?email_source=notifications&email_token=ABTWCMFFJO3SAA6CIXMSRLDP3CVNPA5CNFSM4HYSOUJ2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODX52VPY#issuecomment-503032511, or mute the thread https://github.com/notifications/unsubscribe-auth/ABTWCMDQRFCVV32FOH2AJ63P3CVNPANCNFSM4HYSOUJQ .