[Vegan-commits] r988 - pkg/vegan/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Thu Sep 3 11:21:38 CEST 2009
Author: jarioksa
Date: 2009-09-03 11:21:36 +0200 (Thu, 03 Sep 2009)
New Revision: 988
Modified:
pkg/vegan/R/ordiNAexclude.R
Log:
pad rowsums for cca when na.action = na.exclude
Modified: pkg/vegan/R/ordiNAexclude.R
===================================================================
--- pkg/vegan/R/ordiNAexclude.R 2009-09-03 09:13:53 UTC (rev 987)
+++ pkg/vegan/R/ordiNAexclude.R 2009-09-03 09:21:36 UTC (rev 988)
@@ -35,7 +35,11 @@
## Only do this if omit is of class "exclude"
if (!inherits(omit, "exclude"))
return(x)
- x$rowsum <- napredict(omit, x$rowsum) # or zero here
+ if (!inherits(x, "rda")) {
+ x$rowsum <- napredict(omit, x$rowsum)
+ if (inhertis(omit, "exclude"))
+ x$rowsum[omit] <- x$rowsum.excluded
+ }
if (!is.null(x$CCA)) {
x$CCA$u <- napredict(omit, x$CCA$u)
x$CCA$wa <- napredict(omit, x$CCA$wa)
More information about the Vegan-commits
mailing list