[Bioc-devel] proper way to define an S4 method for 'plot'

Shepherd, Lori Lor|@Shepherd @end|ng |rom Ro@we||P@rk@org
Thu Mar 19 15:19:45 CET 2020


Not sure if its worth mentioning but I saw this type of ERROR when we first started the release in R 4.0.0  when S3 plot functions were not defined in the NAMESPACE. http://bioconductor.org/developers/how-to/troubleshoot-build-report/#s3method

But it could also be from  plot() generic moving from graphics to base


Lori Shepherd

Bioconductor Core Team

Roswell Park Comprehensive Cancer Center

Department of Biostatistics & Bioinformatics

Elm & Carlton Streets

Buffalo, New York 14263

________________________________
From: Bioc-devel <bioc-devel-bounces using r-project.org> on behalf of Martin Morgan <mtmorgan.bioc using gmail.com>
Sent: Tuesday, March 17, 2020 1:33 AM
To: Michael Lawrence <lawrence.michael using gene.com>; Henrik Bengtsson <henrik.bengtsson using gmail.com>
Cc: bioc-devel <bioc-devel using r-project.org>
Subject: Re: [Bioc-devel] proper way to define an S4 method for 'plot'

We'll discuss this and other issues at the developer forum on Thursday (12pm US Eastern) https://stat.ethz.ch/pipermail/bioc-devel/2020-March/016347.html.

The builds are a really big mess at the moment http://bioconductor.org/checkResults/3.11/bioc-LATEST/, with many changes in R-devel causing often easy-to-fix changes. We need developers to step forward and fix their packages.

A variant of the plot generic change I saw while troubleshooting the graph package was due to a stale version of Rgraphviz, installed before the move of the generic. It was resolved by re-installing Rgraphviz, but then I see

> requireNamespace("Rgraphviz")
Loading required namespace: Rgraphviz
Warning message:
multiple methods tables found for ‘plot’

which I am still working to resolve. I'll bump Rgraphviz version number to force re-installation when I'm sure I've got everything figured out.

Martin

On 3/16/20, 7:37 PM, "Bioc-devel on behalf of Michael Lawrence via Bioc-devel" <bioc-devel-bounces using r-project.org on behalf of bioc-devel using r-project.org> wrote:

    At least with 2020-03-16 r77987 (Mac OS) I wasn't able to reproduce this.
    Btw, there's no real need for an S4 method in this case. An S3 method would
    work just as well.

    On Mon, Mar 16, 2020 at 4:12 PM Henrik Bengtsson <henrik.bengtsson using gmail.com>
    wrote:

    > Maybe it's related to:
    >
    > * The plot() S3 generic function is now in package base rather than
    > package graphics, as it is reasonable to have methods that do not use
    > the graphics package. The generic is currently re-exported from the
    > graphics namespace to allow packages importing it from there to
    > continue working, but this may change in future.
    >
    > mentioned in the R 4.0.0 NEWS
    > (https://cran.r-project.org/doc/manuals/r-devel/NEWS.html)?
    >
    > /Henrik
    >
    > On Mon, Mar 16, 2020 at 3:52 PM Vincent Carey
    > <stvjc using channing.harvard.edu> wrote:
    > >
    > > I just updated my R and I am getting into trouble with MLInterfaces
    > > maintenance.
    > >
    > > > BiocManager::install("MLInterfaces")
    > >
    > > *Bioconductor version 3.11 (BiocManager 1.30.10), R Under development
    > > (unstable)*
    > >
    > > *  (2020-03-15 r77975)*
    > >
    > > *Installing package(s) 'MLInterfaces'*
    > >
    > > *Warning: unable to access index for repository
    > > https://cran.rstudio.com/bin/macosx/el-capitan/contrib/4.0
    > > <https://cran.rstudio.com/bin/macosx/el-capitan/contrib/4.0>:*
    > >
    > > *  cannot open URL
    > > 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/4.0/PACKAGES
    > > <https://cran.rstudio.com/bin/macosx/el-capitan/contrib/4.0/PACKAGES>'*
    > >
    > >
    > >   There is a binary version available but the source version is later:
    > >
    > >              binary source needs_compilation
    > >
    > > MLInterfaces 1.67.2 1.67.5             FALSE
    > >
    > >
    > > *installing the source package ‘MLInterfaces’*
    > >
    > >
    > > *trying URL
    > > '
    > https://bioconductor.org/packages/3.11/bioc/src/contrib/MLInterfaces_1.67.5.tar.gz
    > > <
    > https://bioconductor.org/packages/3.11/bioc/src/contrib/MLInterfaces_1.67.5.tar.gz
    > >'*
    > >
    > > *Content type 'application/x-gzip' length 1071876 bytes (1.0 MB)*
    > >
    > > *==================================================*
    > >
    > > *downloaded 1.0 MB*
    > >
    > >
    > > * installing *source* package ‘MLInterfaces’ ...
    > >
    > > ** using staged installation
    > >
    > > ** R
    > >
    > > ** inst
    > >
    > > ** byte-compile and prepare package for lazy loading
    > >
    > > Error in getGeneric(f, TRUE, envir, package) :
    > >
    > >   no generic function found for ‘plot’
    > >
    > > Calls: <Anonymous> ... namespaceImportFrom -> .mergeImportMethods ->
    > > <Anonymous> -> getGeneric
    > >
    > > recover called non-interactively; frames dumped, use debugger() to view
    > >
    > > ** help
    > >
    > > *** installing help indices
    > >
    > > ** building package indices
    > >
    > > ** installing vignettes
    > >
    > > ** testing if installed package can be loaded from temporary location
    > >
    > > Error: package or namespace load failed for ‘MLInterfaces’ in
    > getGeneric(f,
    > > TRUE, envir, package):
    > >
    > >  no generic function found for ‘plot’
    > >
    > >
    > > ...
    > >
    > >
    > > > sessionInfo()
    > >
    > > R Under development (unstable) (2020-03-15 r77975)
    > >
    > > Platform: x86_64-apple-darwin15.6.0 (64-bit)
    > >
    > > Running under: macOS Mojave 10.14.6
    > >
    > >
    > > Matrix products: default
    > >
    > > BLAS:
    > >
    > /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRblas.0.dylib
    > >
    > > LAPACK:
    > >
    > /Library/Frameworks/R.framework/Versions/4.0/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] rmarkdown_2.1
    > >
    > >
    > > loaded via a namespace (and not attached):
    > >
    > >  [1] BiocManager_1.30.10 compiler_4.0.0      startup_0.14.0
    > >
    > >  [4] tools_4.0.0         htmltools_0.4.0     Rcpp_1.0.3
    > >
    > >  [7] codetools_0.2-16    knitr_1.28          xfun_0.12
    > >
    > > [10] digest_0.6.25       rlang_0.4.5         evaluate_0.14
    > >
    > > --
    > > The information in this e-mail is intended only for th...{{dropped:6}}
    >
    > _______________________________________________
    > Bioc-devel using r-project.org mailing list
    > https://stat.ethz.ch/mailman/listinfo/bioc-devel
    >


    --
    Michael Lawrence
    Senior Scientist, Bioinformatics and Computational Biology
    Genentech, A Member of the Roche Group
    Office +1 (650) 225-7760
    michafla using gene.com

    Join Genentech on LinkedIn | Twitter | Facebook | Instagram | YouTube

         [[alternative HTML version deleted]]

    _______________________________________________
    Bioc-devel using r-project.org mailing list
    https://stat.ethz.ch/mailman/listinfo/bioc-devel

_______________________________________________
Bioc-devel using r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/bioc-devel


This email message may contain legally privileged and/or confidential information.  If you are not the intended recipient(s), or the employee or agent responsible for the delivery of this message to the intended recipient(s), you are hereby notified that any disclosure, copying, distribution, or use of this email message is prohibited.  If you have received this message in error, please notify the sender immediately by e-mail and delete this email message from your computer. Thank you.
	[[alternative HTML version deleted]]



More information about the Bioc-devel mailing list