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

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Aug 28 14:41:04 CEST 2013


Author: jarioksa
Date: 2013-08-28 14:41:00 +0200 (Wed, 28 Aug 2013)
New Revision: 2598

Modified:
   pkg/vegan/R/as.mlm.cca.R
   pkg/vegan/R/as.mlm.rda.R
   pkg/vegan/R/eigenvals.R
   pkg/vegan/R/intersetcor.R
   pkg/vegan/inst/ChangeLog
Log:
remove R < 2.12.1 tweaks

Modified: pkg/vegan/R/as.mlm.cca.R
===================================================================
--- pkg/vegan/R/as.mlm.cca.R	2013-08-28 08:56:55 UTC (rev 2597)
+++ pkg/vegan/R/as.mlm.cca.R	2013-08-28 12:41:00 UTC (rev 2598)
@@ -5,10 +5,6 @@
     wa <- x$CCA$wa
     wa <- sweep(wa, 1, sqrt(w), "*")
     X <- qr.X(x$CCA$QR)
-    ## qr.X gives wrong column names now, and they are fixed here
-    ## (hopefully fixed in 2.12.1, but that's only a wish).
-    if (getRversion() <= "2.12.0")
-        colnames(X)[x$CCA$QR$pivot] <- colnames(X)
     lm(wa ~ . - 1, data = as.data.frame(X))
 }
 

Modified: pkg/vegan/R/as.mlm.rda.R
===================================================================
--- pkg/vegan/R/as.mlm.rda.R	2013-08-28 08:56:55 UTC (rev 2597)
+++ pkg/vegan/R/as.mlm.rda.R	2013-08-28 12:41:00 UTC (rev 2598)
@@ -2,10 +2,6 @@
     function (x) 
 {
     X <- qr.X(x$CCA$QR)
-    ## We hope that column names will be fixed in R 2.12.1 (but
-    ## perhaps in vain).
-    if (getRversion() <= "2.12.0")
-        colnames(X)[x$CCA$QR$pivot] <- colnames(X)
     lm(x$CCA$wa ~ . - 1, data = as.data.frame(X))
 }
 

Modified: pkg/vegan/R/eigenvals.R
===================================================================
--- pkg/vegan/R/eigenvals.R	2013-08-28 08:56:55 UTC (rev 2597)
+++ pkg/vegan/R/eigenvals.R	2013-08-28 12:41:00 UTC (rev 2598)
@@ -20,8 +20,7 @@
         else if (length(x) == 3 && all(names(x) %in% c("d", "u", "v")))
             out <- x$d^2
         ## cmdscale() will return all eigenvalues from R  2.12.1
-        else if (getRversion() > "2.12.0" &&
-                 all(c("points","eig","GOF") %in% names(x)))
+        else if (all(c("points","eig","GOF") %in% names(x)))
             out <- x$eig
     }
     class(out) <- "eigenvals"

Modified: pkg/vegan/R/intersetcor.R
===================================================================
--- pkg/vegan/R/intersetcor.R	2013-08-28 08:56:55 UTC (rev 2597)
+++ pkg/vegan/R/intersetcor.R	2013-08-28 12:41:00 UTC (rev 2598)
@@ -8,8 +8,5 @@
         wa <- sweep(object$CCA$wa, 1, sqrt(w), "*")
     }
     X <- qr.X(object$CCA$QR)
-    ## current R (2.12.0) uses wrong column names in pivoted qr.X()
-    if (getRversion() <= "2.12.0")
-        colnames(X)[object$CCA$QR$pivot] <- colnames(X)
     cor(X, wa)
 }

Modified: pkg/vegan/inst/ChangeLog
===================================================================
--- pkg/vegan/inst/ChangeLog	2013-08-28 08:56:55 UTC (rev 2597)
+++ pkg/vegan/inst/ChangeLog	2013-08-28 12:41:00 UTC (rev 2598)
@@ -4,6 +4,8 @@
 
 Version 2.1-34 (opened August 28, 2013)
 
+	* DESCRIPTION: dependent on R >= 2.14.0.
+	
 	* DESCRIPTION, vignettes: R 3.0.2-to-be checks with --as-cran
 	requires (with a NOTE) the vignettes source files (Rnw) to be in
 	vignettes/ directory.  Because Makefile is not executed in
@@ -12,9 +14,11 @@
 	to move those to inst/doc after building. This also made
 	/.Rinstignore unnecessary. The vignettes directory was introduced
 	and made recommended in R 2.14.0 so that the this version of vegan
-	depends on R >= 2.14.0.  With this, some of the parallel code
-	that is also dependent on 2.14.0 could be simplified as no version
-	checking is necessary.
+	depends on R >= 2.14.0. 
+
+	* tweaks for R < 2.12.1 removed: code to fix buggy naming of
+	columns in qr.X before 2.12.1 (as.mlm.cca/rda, intersetcor), and
+	change in the cmdscale() output (eigenvals.default).
 	
 Version 2.1-33 (closed August 28, 2013)
 
@@ -22,7 +26,7 @@
 	checks with NOTE on ':::' calls to tools:::httpdPort (to launch
 	reading vegan NEWS.html in existing browser window) and
 	parallel:::.reg to acces the defaultCluster in an unexported
-	function in parallel Namespace.
+	environment within 'parallel' Namespace.
 	
 Version 2.1-32 (closed August 19, 2013)
 



More information about the Vegan-commits mailing list