Skip to content
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

D3heatmap redifining print function for characters and numerics #91

Open
eloimercier-stemcell opened this issue Jul 6, 2021 · 2 comments

Comments

@eloimercier-stemcell
Copy link

eloimercier-stemcell commented Jul 6, 2021

D3heatmap redefines the base function "print" for character and numeric. The help menu suggests that the d3heatmap::print function should only be called on a d3heatmapGadget.
As you can imagine, every piece of code using the base::print function is now broken after loading d3heatmap.

> print("a")
[1] "a"
> print(2)
[1] 2
> library(d3heatmap)

======================
Welcome to d3heatmap version 0.9.0
[...]
Attaching package: ‘d3heatmap’

The following objects are masked from ‘package:base’:

    print, save

> print("a")
Error in (function (classes, fdef, mtable)  : 
  unable to find an inherited method for function ‘print’ for signature ‘"character"’

> print(2)
Error in (function (classes, fdef, mtable)  : 
  unable to find an inherited method for function ‘print’ for signature ‘"numeric"’

> sessionInfo()
R version 4.1.0 (2021-05-18)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 17134)

Matrix products: default

locale:
[1] LC_COLLATE=English_Canada.1252  LC_CTYPE=English_Canada.1252    LC_MONETARY=English_Canada.1252 LC_NUMERIC=C                   
[5] LC_TIME=English_Canada.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] d3heatmap_0.9.0

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.6        knitr_1.33        magrittr_2.0.1    xtable_1.8-4      R6_2.5.0          rlang_0.4.11      fastmap_1.1.0     stringr_1.4.0    
 [9] plyr_1.8.6        gProfileR_0.7.0   tools_4.1.0       DT_0.18           xfun_0.24         png_0.1-7         htmltools_0.5.1.1 shinyjs_2.0.0    
[17] ellipsis_0.3.2    digest_0.6.27     lifecycle_1.0.0   zip_2.2.0         shiny_1.6.0       reshape2_1.4.4    later_1.2.0       base64enc_0.1-3  
[25] htmlwidgets_1.5.3 promises_1.2.0.1  evaluate_0.14     mime_0.11         rmarkdown_2.9     openxlsx_4.2.4    limma_3.48.1      stringi_1.6.2    
[33] compiler_4.1.0    httpuv_1.6.1 
@kforthman
Copy link

I have also run into this issue. I have to detach d3heatmap in order to use the print function.

@talgalili
Copy link
Owner

talgalili commented Jan 21, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants