[BioC] Rgraphviz: fail to plot

HÃ¥vard Rue [guest] guest at bioconductor.org
Wed Jan 25 19:30:59 CET 2012


I upgraded Rgraphviz, and now it fails to plot even the first example,

> set.seed(123)
> V <- letters[1:10]
> M <- 1:4
> g1 <- randomGraph(V, M, 0.2)
> plot(g1)
Error in as.double(y) : 
  cannot coerce type 'S4' to vector of type 'double'

seems like no 'plot method' is defined for the graph; but this sounds like something else is going on. 

Anyone with a similar problem?

Best
H

 -- output of sessionInfo(): 

$ R --vanilla

R version 2.14.1 (2011-12-22)
Copyright (C) 2011 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: x86_64-redhat-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(Rgraphviz)
Loading required package: graph
Loading required package: grid
> set.seed(123)
> V <- letters[1:10]
> M <- 1:4
> 
> 
> ###################################################
> ### code chunk number 2: createGraph2
> ###################################################
> g1 <- randomGraph(V, M, 0.2)
> plot(g1)
Error in as.double(y) : 
  cannot coerce type 'S4' to vector of type 'double'
> sessionInfo()
R version 2.14.1 (2011-12-22)
Platform: x86_64-redhat-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_GB.utf8       LC_NUMERIC=C             
 [3] LC_TIME=en_DK.utf8        LC_COLLATE=en_GB.utf8    
 [5] LC_MONETARY=en_GB.utf8    LC_MESSAGES=en_GB.utf8   
 [7] LC_PAPER=C                LC_NAME=C                
 [9] LC_ADDRESS=C              LC_TELEPHONE=C           
[11] LC_MEASUREMENT=en_GB.utf8 LC_IDENTIFICATION=C      

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

other attached packages:
[1] Rgraphviz_1.32.0 graph_1.32.0    

loaded via a namespace (and not attached):
[1] lattice_0.20-0 Matrix_1.0-2   pixmap_0.4-11  sp_0.9-91      tools_2.14.1  
> 


--
Sent via the guest posting facility at bioconductor.org.



More information about the Bioconductor mailing list