[Vegan-commits] r1632 - in branches/1.17: R inst man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Tue Jun 14 08:42:31 CEST 2011


Author: jarioksa
Date: 2011-06-14 08:42:27 +0200 (Tue, 14 Jun 2011)
New Revision: 1632

Added:
   branches/1.17/R/anova.prc.R
Modified:
   branches/1.17/inst/ChangeLog
   branches/1.17/inst/NEWS
   branches/1.17/man/anova.cca.Rd
Log:
merged r1629,30: add anova.prc

Copied: branches/1.17/R/anova.prc.R (from rev 1629, pkg/vegan/R/anova.prc.R)
===================================================================
--- branches/1.17/R/anova.prc.R	                        (rev 0)
+++ branches/1.17/R/anova.prc.R	2011-06-14 06:42:27 UTC (rev 1632)
@@ -0,0 +1,24 @@
+`anova.prc` <-
+    function(object, ...)
+{
+    ## if user specified 'by', cast prc() to an rda() and call anova
+    ## on its result
+    extras <- match.call(expand.dots = FALSE)
+    if ("by" %in% names(extras$...)) {
+        Y <- as.character(object$call$response)
+        X <- as.character(object$call$treatment)
+        Z <- as.character(object$call$time)
+        fla <- paste(Y, "~", X, "*", Z, "+ Condition(", Z, ")")
+        fla <- as.formula(fla)
+        ## get extras
+        m <- match(c("data", "scale", "subset", "na.action"),
+                   names(object$call), 0)
+        call <- object$call[c(1,m)]
+        call$formula <- fla
+        call[[1]] <- as.name("rda.formula")
+        object <- eval(call, parent.frame())
+        anova(object, ...)
+    } else {
+        NextMethod("anova", object, ...)
+    }    
+}

Modified: branches/1.17/inst/ChangeLog
===================================================================
--- branches/1.17/inst/ChangeLog	2011-06-13 23:40:56 UTC (rev 1631)
+++ branches/1.17/inst/ChangeLog	2011-06-14 06:42:27 UTC (rev 1632)
@@ -4,8 +4,10 @@
 
 Version 1.17-11 (opened April 29, 2011)
 
-	* merger r1625,6: Ref to our MEE paper in anova.cca.Rd.
+	* merged r1629,30: added anova.prc().
 	
+	* merged r1625,6: Ref to our MEE paper in anova.cca.Rd.
+	
 	* merged r1624: doc vegdist(..., "raup") not using unequal
 	sampling probabilities for species.
 

Modified: branches/1.17/inst/NEWS
===================================================================
--- branches/1.17/inst/NEWS	2011-06-13 23:40:56 UTC (rev 1631)
+++ branches/1.17/inst/NEWS	2011-06-14 06:42:27 UTC (rev 1632)
@@ -12,18 +12,21 @@
       components changed. They are no longer made NULL and left
       undisplayed, but now they are shown as zero rank. The general
       output also changed so that proportions of inertia are only
-      shown if there are conditions or constrains, but not for
+      shown if there are conditions or constraints, but not for
       unconstrained analysis. The capscale() function no longer shows
-      species scores if these are unvailable. Several support
+      species scores if these are unavailable. Several support
       functions more robust.
 
     - nobs: R 2.13.0 introduced generic function nobs() to find the
-      number of observations, and this releae provides nobs() for
-      several vegan results. However, this does not make vegan
-      dependent on R 2.13.0, but it can be used with older functions
-      as well.
+      number of observations, and this release provides nobs() for
+      several vegan results. (This does not make vegan dependent on R
+      2.13.0, but vegan works with older R as well.)
 
-    - specaccum: gained arumgent 'groups' which can be used to find
+    - prc: allows anova(..., by = "axis") and other 'by' cases for
+      prc() results. Some rda() support functions still fail, but now
+      they stop informatively.
+
+    - specaccum: gained argument 'groups' which can be used to find
       the number of species in subsets of the data.
 
 		       CHANGES IN VEGAN 1.17-10

Modified: branches/1.17/man/anova.cca.Rd
===================================================================
--- branches/1.17/man/anova.cca.Rd	2011-06-13 23:40:56 UTC (rev 1631)
+++ branches/1.17/man/anova.cca.Rd	2011-06-14 06:42:27 UTC (rev 1632)
@@ -4,6 +4,7 @@
 \alias{anova.ccabyaxis}
 \alias{anova.ccabyterm}
 \alias{anova.ccabymargin}
+\alias{anova.prc}
 \alias{permutest}
 \alias{permutest.default}
 \alias{permutest.cca}



More information about the Vegan-commits mailing list