[Vegan-commits] r369 - in pkg: R inst
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sat May 24 10:56:34 CEST 2008
Author: gsimpson
Date: 2008-05-24 10:56:34 +0200 (Sat, 24 May 2008)
New Revision: 369
Modified:
pkg/R/permutest.betadisper.R
pkg/inst/ChangeLog
Log:
Fix pair-wise permutation p-values. Reported by Dan O'Shea.
Modified: pkg/R/permutest.betadisper.R
===================================================================
--- pkg/R/permutest.betadisper.R 2008-05-23 06:20:19 UTC (rev 368)
+++ pkg/R/permutest.betadisper.R 2008-05-24 08:56:34 UTC (rev 369)
@@ -56,7 +56,7 @@
length(x$distance[x$group == z[2]]) - 2})
pairwise <- list(observed = 2 * pt(-abs(t.stats[1,]), df),
permuted = apply(t.stats, 2,
- function(z) sum(abs(z) >= z[1])/length(z)))
+ function(z) sum(abs(z) >= abs(z[1]))/length(z)))
names(pairwise$observed) <- names(pairwise$permuted) <-
apply(combin, 2, paste, collapse = "-")
} else {
Modified: pkg/inst/ChangeLog
===================================================================
--- pkg/inst/ChangeLog 2008-05-23 06:20:19 UTC (rev 368)
+++ pkg/inst/ChangeLog 2008-05-24 08:56:34 UTC (rev 369)
@@ -16,7 +16,10 @@
* inertcomp and intersetcor only work with objects inheriting from
"cca", but they did not check that the object was of the correct
type and so could end up with calling weights.default or give
- obscure error messages.
+ obscure error messages.
+
+ * permutest.betadisper: Could give the wrong pair-wise permutation
+ p-values. Reported by Daniel O'Shea.
Version 1.14-0 (closed May 21, 2008)
More information about the Vegan-commits
mailing list