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

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sun Sep 29 07:33:24 CEST 2013


Author: jarioksa
Date: 2013-09-29 07:33:22 +0200 (Sun, 29 Sep 2013)
New Revision: 2628

Modified:
   pkg/vegan/R/ordiArrowMul.R
   pkg/vegan/inst/ChangeLog
Log:
plotting vectors failed if one variable was invariable and no vector could be calculated for it

Modified: pkg/vegan/R/ordiArrowMul.R
===================================================================
--- pkg/vegan/R/ordiArrowMul.R	2013-09-27 12:17:04 UTC (rev 2627)
+++ pkg/vegan/R/ordiArrowMul.R	2013-09-29 05:33:22 UTC (rev 2628)
@@ -5,7 +5,7 @@
 {
     u <- par("usr")
     u <- u - rep(at, each = 2)
-    r <- c(range(x[,1]), range(x[,2]))
+    r <- c(range(x[,1], na.rm = TRUE), range(x[,2], na.rm = TRUE))
     ## 'rev' takes care of reversed axes like xlim(1,-1)
     rev <- sign(diff(u))[-2]
     if (rev[1] < 0)

Modified: pkg/vegan/inst/ChangeLog
===================================================================
--- pkg/vegan/inst/ChangeLog	2013-09-27 12:17:04 UTC (rev 2627)
+++ pkg/vegan/inst/ChangeLog	2013-09-29 05:33:22 UTC (rev 2628)
@@ -6,6 +6,11 @@
 
 	* opened with the release of vegan 2.0-9.
 
+	* envfit: if a variable is constant, no fitted vector can be
+	calculated and results will be given as NA (with
+	warnings). Plotting of all vectors will fail in such cases because
+	no finite scale was found for arrows. Fixed on ordiArrowMul.
+
 	* nestednodf: matrix fill was wrongly calculated in weighted
 	analysis. The nominator was length of 'comm', and if input was a
 	data frame that was the number of columns instead of the number of



More information about the Vegan-commits mailing list