[Vegan-commits] r2989 - pkg/vegan/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Tue Feb 23 15:47:03 CET 2016
Author: jarioksa
Date: 2016-02-23 15:47:03 +0100 (Tue, 23 Feb 2016)
New Revision: 2989
Modified:
pkg/vegan/R/betadiver.R
pkg/vegan/R/linestack.R
pkg/vegan/R/simper.R
Log:
Merge branch 'cran-2.3' into r-forge-svn-local
Modified: pkg/vegan/R/betadiver.R
===================================================================
--- pkg/vegan/R/betadiver.R 2016-01-12 14:16:01 UTC (rev 2988)
+++ pkg/vegan/R/betadiver.R 2016-02-23 14:47:03 UTC (rev 2989)
@@ -20,7 +20,7 @@
"co"="(a*c+a*b+2*b*c)/(2*(a+b)*(a+c))",
"cc"="(b+c)/(a+b+c)", "g"="(b+c)/(a+b+c)",
"-3"="pmin(b,c)/(a+b+c)", "l"="(b+c)/2",
- "19"="2*(b*c+1)/((a+b+c)^2+(a+b+c))",
+ "19"="2*(b*c+1)/((a+b+c)^2-(a+b+c))",
"hk"="(b+c)/(2*a+b+c)", "rlb"="a/(a+c)",
"sim"="pmin(b,c)/(pmin(b,c)+a)",
"gl"="2*abs(b-c)/(2*a+b+c)",
Modified: pkg/vegan/R/linestack.R
===================================================================
--- pkg/vegan/R/linestack.R 2016-01-12 14:16:01 UTC (rev 2988)
+++ pkg/vegan/R/linestack.R 2016-02-23 14:47:03 UTC (rev 2989)
@@ -2,14 +2,19 @@
function (x, labels, cex = 0.8, side = "right", hoff = 2, air = 1.1,
at = 0, add = FALSE, axis = FALSE, ...)
{
+ if (length(at) > 1 || length(hoff) > 1 || length(air) > 1 || length(cex) > 1)
+ stop("only one value accepted for arguments 'cex', 'hoff', 'air' and 'at'")
x <- drop(x)
n <- length(x)
misslab <- missing(labels)
if (misslab) {
labels <- names(x)
}
+ if (!is.character(labels))
+ labels <- as.character(labels)
nlab <- length(labels)
- if (!misslab && nlab == 1L && pmatch(labels, c("right", "left"), nomatch = FALSE)) {
+ if (!misslab && nlab == 1L && pmatch(labels, c("right", "left"),
+ nomatch = FALSE)) {
side <- labels
labels <- NULL
warning("argument 'label' is deprecated: use 'side'")
@@ -30,7 +35,7 @@
plot(pos, x, type = "n", axes = FALSE, xlab = "", ylab = "", ...)
}
hoff <- hoff * strwidth("m")
- ht <- air * strheight(names(x), cex = cex)
+ ht <- air * strheight(labels, cex = cex)
mid <- (n + 1)%/%2
pos[mid] <- x[mid]
if (n > 1) {
Modified: pkg/vegan/R/simper.R
===================================================================
--- pkg/vegan/R/simper.R 2016-01-12 14:16:01 UTC (rev 2988)
+++ pkg/vegan/R/simper.R 2016-02-23 14:47:03 UTC (rev 2989)
@@ -126,8 +126,8 @@
{
if (ordered) {
out <- lapply(object, function(z)
- data.frame(contr = z$average, sd = z$sd, ratio = z$ratio,
- av.a = z$ava, av.b = z$avb)[z$ord, ])
+ data.frame(average = z$average, sd = z$sd, ratio = z$ratio,
+ ava = z$ava, avb = z$avb)[z$ord, ])
cusum <- lapply(object, function(z) z$cusum)
for(i in seq_along(out)) {
out[[i]]$cumsum <- cusum[[i]]
More information about the Vegan-commits
mailing list