[Phylobase-commits] r609 - pkg/man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Aug 31 03:20:55 CEST 2009


Author: pdc
Date: 2009-08-31 03:20:54 +0200 (Mon, 31 Aug 2009)
New Revision: 609

Modified:
   pkg/man/plotOneTree.Rd
   pkg/man/treePlot-methods.Rd
Log:
Move example to more appropriate place.  Remove calls to prune() to prepare for incoming changes to said function. See Bug #616.



Modified: pkg/man/plotOneTree.Rd
===================================================================
--- pkg/man/plotOneTree.Rd	2009-08-31 01:18:05 UTC (rev 608)
+++ pkg/man/plotOneTree.Rd	2009-08-31 01:20:54 UTC (rev 609)
@@ -29,6 +29,7 @@
 \examples{
 
 data(geospiza)
+grid.newpage()
 xxyy <- phyloXXYY(geospiza)
 plotOneTree(xxyy, type = 'phylogram', 
   show.tip.label = TRUE, show.node.label = TRUE,
@@ -45,19 +46,6 @@
 )
 popViewport()
 
-## example of plotting two grid plots on the same page
-geotree <- extractTree(geospiza)
-geotree2 <-
-prune(geotree,descendants(geotree,MRCA(geotree,c("difficilis","scandens"))),
-subtree=TRUE)
-  grid.newpage()
-  pushViewport(viewport(layout=grid.layout(nrow=1,ncol=2),name="base"))
-  pushViewport(viewport(layout.pos.col=1,name="plot1"))
-  plot(geotree,newpage=FALSE)
-  popViewport()
-  pushViewport(viewport(layout.pos.col=2,name="plot2"))
-  plot(geotree2,newpage=FALSE,rot=180)
-  popViewport()
 }
 
 \keyword{methods}

Modified: pkg/man/treePlot-methods.Rd
===================================================================
--- pkg/man/treePlot-methods.Rd	2009-08-31 01:18:05 UTC (rev 608)
+++ pkg/man/treePlot-methods.Rd	2009-08-31 01:20:54 UTC (rev 609)
@@ -48,5 +48,21 @@
 
 \seealso{ \code{\link{phylobubbles}}  }
 
+\examples{
 
+## example of plotting two grid plots on the same page
+data(geospiza)
+geotree <- extractTree(geospiza)
+grid.newpage()
+pushViewport(viewport(layout=grid.layout(nrow=1, ncol=2), name="base"))
+  pushViewport(viewport(layout.pos.col=1, name="plot1"))
+    treePlot(geotree, newpage=FALSE)
+  popViewport()
+  
+  pushViewport(viewport(layout.pos.col=2, name="plot2"))
+    treePlot(geotree, newpage=FALSE, rot=180)
+popViewport(2)
+
+}
+
 \keyword{methods}



More information about the Phylobase-commits mailing list