[Vegan-commits] r2372 - in pkg/vegan: R inst

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Tue Jan 15 18:20:54 CET 2013


Author: gsimpson
Date: 2013-01-15 18:20:54 +0100 (Tue, 15 Jan 2013)
New Revision: 2372

Modified:
   pkg/vegan/R/ordilabel.R
   pkg/vegan/inst/ChangeLog
Log:
make use of ordiArgAbsorber() when drawing

Modified: pkg/vegan/R/ordilabel.R
===================================================================
--- pkg/vegan/R/ordilabel.R	2013-01-15 08:34:47 UTC (rev 2371)
+++ pkg/vegan/R/ordilabel.R	2013-01-15 17:20:54 UTC (rev 2372)
@@ -29,10 +29,15 @@
         else
             col <- par("fg")
     for (i in 1:nrow(x)) {
-        polygon(x[i,1] + c(-1,1,1,-1)*w[i], x[i,2] + c(-1,-1,1,1)*h[i],
-                col = fill, border = border, xpd = xpd)
-        text(x[i,1], x[i,2], labels = labels[i], cex = cex, col = col,
-             xpd = xpd, ...)
+        ## polygon(x[i,1] + c(-1,1,1,-1)*w[i], x[i,2] + c(-1,-1,1,1)*h[i],
+        ##         col = fill, border = border, xpd = xpd)
+        ## text(x[i,1], x[i,2], labels = labels[i], cex = cex, col = col,
+        ##      xpd = xpd, ...)
+        ordiArgAbsorber(x[i,1] + c(-1,1,1,-1)*w[i], x[i,2] + c(-1,-1,1,1)*h[i],
+                        col = fill, border = border, xpd = xpd,
+                        FUN = polygon, ...)
+        ordiArgAbsorber(x[i,1], x[i,2], labels = labels[i], cex = cex,
+                        col = col, xpd = xpd, FUN = text, ...)
     }
     invisible(x)
 }

Modified: pkg/vegan/inst/ChangeLog
===================================================================
--- pkg/vegan/inst/ChangeLog	2013-01-15 08:34:47 UTC (rev 2371)
+++ pkg/vegan/inst/ChangeLog	2013-01-15 17:20:54 UTC (rev 2372)
@@ -46,6 +46,9 @@
 	* wcmdscale: added method functions print(), plot() and
 	scores(). Now class "wcmdscale" results also retun the function
 	call and dimensions have names.
+
+	* ordilabel: was missing ordiArgAbsorber() on the plotting calls
+	to text() and polygon(). Thus lots of warnings were raised in use.
 	
 Version 2.1-22 (closed January 8, 2013)
 



More information about the Vegan-commits mailing list