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

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Tue Jul 19 14:19:36 CEST 2011


Author: jarioksa
Date: 2011-07-19 14:19:35 +0200 (Tue, 19 Jul 2011)
New Revision: 1683

Modified:
   pkg/vegan/R/anova.cca.R
   pkg/vegan/inst/ChangeLog
Log:
anova.cca failed if CCA had zero rank

Modified: pkg/vegan/R/anova.cca.R
===================================================================
--- pkg/vegan/R/anova.cca.R	2011-07-17 06:25:09 UTC (rev 1682)
+++ pkg/vegan/R/anova.cca.R	2011-07-19 12:19:35 UTC (rev 1683)
@@ -2,7 +2,8 @@
     function (object, alpha = 0.05, beta = 0.01, step = 100, perm.max = 9999, 
               by = NULL, ...) 
 {
-    if (is.null(object$CA) || is.null(object$CCA))
+    if (is.null(object$CA) || is.null(object$CCA) ||
+        object$CCA$rank == 0 || object$CA$rank == 0)
         return(anova.ccanull(object))
     perm.max <- max(step-1, perm.max)
     if (perm.max %% step == 0)

Modified: pkg/vegan/inst/ChangeLog
===================================================================
--- pkg/vegan/inst/ChangeLog	2011-07-17 06:25:09 UTC (rev 1682)
+++ pkg/vegan/inst/ChangeLog	2011-07-19 12:19:35 UTC (rev 1683)
@@ -4,6 +4,10 @@
 
 Version 1.90-1 (opened July 3, 2011)
 
+	* anova.cca: failed (bug) if CCA object had rank zero. This was
+	broken by the new CCA return object, where completely aliased
+	constraints do not give NULL component but a zero rank component. 
+
 	* swan: gained argument 'maxit' that can be used to restrict the
 	number of beals() passes on zeros. The default is 'maxit = Inf'
 	which is the old behaviour: beals() passes on zero entries



More information about the Vegan-commits mailing list