Question: Error in windows() function
gravatar for a
28 days ago by
a0 wrote:


I just upgraded R 3.5.1 via CRAN and I am trying to use "windows()" function after loading "Biostrings" library like this:

> source("")
> biocLite("Biostrings")
> library(Biostrings)
> windows()

I get the following error messages:

Error in (function (classes, fdef, mtable)  : 
unable to find an inherited method for function ‘windows’ for signature ‘"missing"’

In R 3.4.4, that "windows()" function works well. Do you know how to fix it?

My environment is as follows:

Microsoft Windows [Version 10.0.17134.345]

> R.version
platform       x86_64-w64-mingw32          
arch           x86_64                      
os             mingw32                     
system         x86_64, mingw32             
major          3                           
minor          5.1                         
year           2018                        
month          07                          
day            02                          
svn rev        74947                       
language       R                           
version.string R version 3.5.1 (2018-07-02)
nickname       Feather Spray



ADD COMMENTlink modified 27 days ago by Mike Smith3.1k • written 28 days ago by a0

What exactly are you trying to do?  That error essentially says "this function does not work when you provide no arguments".  It would be more typical to provide a specific variable to the function.

ADD REPLYlink written 28 days ago by Mike Smith3.1k

Hi Mike,

Thanks for the prompt response. It seems the description is too short. I would like to display two screens side by side with windows() function.

That error occurs only after loading some specific libraries, "Biostrings" and "AnnotationDbi".

A following link is an example image to display:

ADD REPLYlink modified 27 days ago • written 27 days ago by a0
gravatar for Mike Smith
27 days ago by
Mike Smith3.1k
EMBL Heidelberg / de.NBI
Mike Smith3.1k wrote:

This issue is being caused by a property called masking.  There are two methods called windows(), one is available in base R (via a package called grDevices) and the other in Biostrings.  In a fresh new R session only the method that opens a graphical windows is available & so it works.  However, once you load Biostrings the method in that package (which does something completely different) take precedence.  

If you want to ensure you use the other version you can use the package name and :: nomenclature to call the windows function e.g.

ADD COMMENTlink modified 26 days ago • written 27 days ago by Mike Smith3.1k

Hi Mike,

Your explanation really helps. That makes total sense. Thank you, Mike!

ADD REPLYlink modified 26 days ago • written 26 days ago by a0
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.2.0
Traffic: 403 users visited in the last hour