[Vegan-commits] r2022 - in branches/2.0: . R inst man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Thu Dec 15 12:57:25 CET 2011
Author: jarioksa
Date: 2011-12-15 12:57:25 +0100 (Thu, 15 Dec 2011)
New Revision: 2022
Added:
branches/2.0/R/nestedbetasor.R
Modified:
branches/2.0/NAMESPACE
branches/2.0/inst/ChangeLog
branches/2.0/inst/NEWS.Rd
branches/2.0/man/betadiver.Rd
branches/2.0/man/diversity.Rd
branches/2.0/man/fisherfit.Rd
branches/2.0/man/nestedtemp.Rd
Log:
merge r2018,19,21 (add nestedbetasor/jac) and r2015 (Bob O'Hara's email)
Modified: branches/2.0/NAMESPACE
===================================================================
--- branches/2.0/NAMESPACE 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/NAMESPACE 2011-12-15 11:57:25 UTC (rev 2022)
@@ -13,6 +13,7 @@
indpower, inertcomp, initMDS, intersetcor, isomapdist, isomap,
linestack, mantel, meandist, metaMDSdist, metaMDSiter, metaMDSredist,
MDSrotate, metaMDS, monoMDS, mrpp, msoplot, mso, multipart,
+nestedbetajac, nestedbetasor,
nestedchecker, nesteddisc, nestedn0, nestednodf, nestedtemp, oecosimu,
ordiR2step, ordiarrows, ordicloud, ordicluster,
ordiellipse, ordigrid, ordihull, ordilabel, ordiplot3d,
Copied: branches/2.0/R/nestedbetasor.R (from rev 2018, pkg/vegan/R/nestedbetasor.R)
===================================================================
--- branches/2.0/R/nestedbetasor.R (rev 0)
+++ branches/2.0/R/nestedbetasor.R 2011-12-15 11:57:25 UTC (rev 2022)
@@ -0,0 +1,36 @@
+### Multiple-site dissimilarity indices (Sorensen & Jaccard) and their
+### decomposition into "turnover" and "nestedness" following Baselga
+### (Global Ecology & Biogeography 19, 134-143; 2010). Implemented as
+### nestedness functions and directly usable in oecosimu().
+
+`nestedbetasor` <-
+ function(comm)
+{
+ beta <- betadiver(comm, method = NA)
+ b <- beta$b
+ c <- beta$c
+ diffbc <- sum(abs(b-c))
+ sumbc <- sum(b+c)
+ bmin <- sum(pmin(b, c))
+ a <- sum(comm) - sum(colSums(comm) > 0)
+ simpson <- bmin/(bmin + a)
+ nest <- a/(bmin + a) * diffbc/(2*a + sumbc)
+ sorensen <- sumbc/(2*a + sumbc)
+ c(turnover = simpson, nestedness = nest, sorensen = sorensen)
+}
+
+`nestedbetajac` <-
+ function(comm)
+{
+ beta <- betadiver(comm, method = NA)
+ b <- beta$b
+ c <- beta$c
+ diffbc <- sum(abs(b-c))
+ sumbc <- sum(b+c)
+ bmin <- sum(pmin(b, c))
+ a <- sum(comm) - sum(colSums(comm) > 0)
+ simpson <- 2*bmin/(2*bmin + a)
+ nest <- a/(2*bmin + a) * diffbc/(a + sumbc)
+ jaccard <- sumbc/(a + sumbc)
+ c(turnover = simpson, nestedness = nest, jaccard = jaccard)
+}
Modified: branches/2.0/inst/ChangeLog
===================================================================
--- branches/2.0/inst/ChangeLog 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/inst/ChangeLog 2011-12-15 11:57:25 UTC (rev 2022)
@@ -4,8 +4,10 @@
Version 2.0-3 (opened November 13, 2011)
+ * merge r2018,19,21: add nestedbetasor() & nestedbetajac().
* merge r2016: empty factor levels in betadisper() fixed in
ordimedian().
+ * merge r2015: remove Bob O'Hara's old email address.
* merge r2008,9,11,12: add rarecurve.
* merge r2007: FAQ update for arrow scaling.
* merge r2004: metaMDS(..., noshare=0) triggers stepacross(), but
Modified: branches/2.0/inst/NEWS.Rd
===================================================================
--- branches/2.0/inst/NEWS.Rd 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/inst/NEWS.Rd 2011-12-15 11:57:25 UTC (rev 2022)
@@ -7,6 +7,11 @@
\subsection{NEW FUNCTIONS}{
\itemize{
+ \item Added new nestedness functions \code{nestedbetasor} and
+ \code{nestedbetajac} that implement multiple-site dissimilarity
+ indices of Baselga (\emph{Global Ecology and Biogeography} 19,
+ 134--143; 2010).
+
\item Added function \code{rarecurve} to draw rarefaction curves
for each row (sampling unit) of the input data, optionally with
lines showing rarefied species richness with given sample size
Modified: branches/2.0/man/betadiver.Rd
===================================================================
--- branches/2.0/man/betadiver.Rd 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/man/betadiver.Rd 2011-12-15 11:57:25 UTC (rev 2022)
@@ -98,20 +98,34 @@
with a warning. }
\references{
-Koleff, P., Gaston, K.J. and Lennon, J.J. (2003) Measuring beta
-diversity for presence-absence data. \emph{Journal of Animal Ecology}
-72, 367--382.
-Whittaker, R.H. (1960) Vegetation of Siskiyou mountains, Oregon and
- California. \emph{Ecological Monographs} 30, 279--338.
+ Baselga, A. (2010) Partitioning the turnover and nestedness
+ components of beta diversity. \emph{Global Ecology and Biogeography}
+ 19, 134--143.
+
+ Koleff, P., Gaston, K.J. and Lennon, J.J. (2003) Measuring beta
+ diversity for presence-absence data. \emph{Journal of Animal
+ Ecology} 72, 367--382.
+
+ Whittaker, R.H. (1960) Vegetation of Siskiyou mountains, Oregon and
+ California. \emph{Ecological Monographs} 30, 279--338.
+
}
+
\author{Jari Oksanen }
\section{Warning }{Some indices return similarities instead of dissimilarities.}
\seealso{ \code{\link{designdist}} for an alternative to implement all
-these functions, \code{\link{vegdist}} for some canned alternatives,
-and \code{\link{betadisper}}, \code{\link{adonis}},
-\code{\link{mantel}} for analysing beta diversity objects.}
+ these functions, \code{\link{vegdist}} for some canned alternatives,
+ and \code{\link{betadisper}}, \code{\link{adonis}},
+ \code{\link{mantel}} for analysing beta diversity objects.
+ Functions \code{\link{nestedbetasor}} and
+ \code{\link{nestedbetajac}} implement decomposition beta diversity
+ measures (\enc{Sørensen}{Sorensen} and Jaccard) into turnover and
+ nestedness components following Baselga (2010).
+}
+
+
\examples{
## Raw data and plotting
data(sipoo)
Modified: branches/2.0/man/diversity.Rd
===================================================================
--- branches/2.0/man/diversity.Rd 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/man/diversity.Rd 2011-12-15 11:57:25 UTC (rev 2022)
@@ -149,8 +149,7 @@
\seealso{Function \code{renyi} for generalized \enc{Rényi}{Renyi}
diversity and Hill numbers.}
-\author{ Jari Oksanen and Bob O'Hara \email{bob.ohara at helsinki.fi}
- (\code{fisher.alpha}).}
+\author{ Jari Oksanen and Bob O'Hara (\code{fisher.alpha}).}
\examples{
data(BCI)
Modified: branches/2.0/man/fisherfit.Rd
===================================================================
--- branches/2.0/man/fisherfit.Rd 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/man/fisherfit.Rd 2011-12-15 11:57:25 UTC (rev 2022)
@@ -186,8 +186,7 @@
distribution. \emph{Journal of Animal Ecology} 74, 409--422.
}
-\author{Bob O'Hara \email{bob.ohara at helsinki.fi} (\code{fisherfit})
-and Jari Oksanen. }
+\author{Bob O'Hara (\code{fisherfit}) and Jari Oksanen. }
\seealso{\code{\link{diversity}}, \code{\link{fisher.alpha}},
\code{\link{radfit}}, \code{\link{specpool}}. Function
Modified: branches/2.0/man/nestedtemp.Rd
===================================================================
--- branches/2.0/man/nestedtemp.Rd 2011-12-15 11:31:21 UTC (rev 2021)
+++ branches/2.0/man/nestedtemp.Rd 2011-12-15 11:57:25 UTC (rev 2022)
@@ -5,6 +5,8 @@
\alias{nestedn0}
\alias{nesteddisc}
\alias{nestednodf}
+\alias{nestedbetasor}
+\alias{nestedbetajac}
\alias{plot.nestedtemp}
\title{ Nestedness Indices for Communities of Islands or Patches }
@@ -22,6 +24,8 @@
nesteddisc(comm)
nestedtemp(comm, ...)
nestednodf(comm, order = TRUE, weighted = FALSE)
+nestedbetasor(comm)
+nestedbetajac(comm)
\method{plot}{nestedtemp}(x, kind = c("temperature", "incidence"),
col=rev(heat.colors(100)), names = FALSE, ...)
}
@@ -106,8 +110,28 @@
al. 2008). With \code{weighted = TRUE}, the function finds the
weighted version of the index (Almeida-Neto & Ulrich,
2011). However, this requires quantitative null models for adequate
- testing.}
+ testing.
+ Functions \code{nestedbetasor} and \code{nestedbetajac} find
+ multiple-site dissimilarities and decompose these into components of
+ turnover and nestedness following Baselga (2010). This can be seen
+ as a decomposition of beta diversity (see \code{\link{betadiver}}).
+ Function \code{nestedbetasor} uses \enc{Sørensen}{Sorensen}
+ dissimilarity and the turnover component is Simpson dissimilarity
+ (Baselga 2010), and \code{nestedbetajac} uses analogous methods with
+ the Jaccard index. The functions return a vector of three items:
+ turnover, nestedness and their sum which is the multiple
+ \enc{Sørensen}{Sorensen} or Jaccard dissimilarity. The last one is
+ the total beta diversity (Baselga 2010). The functions will treat
+ data as presence/absence (binary) and they can be used with binary
+ null models (see \code{\link{commsimulator}}). The overall
+ dissimilarity is constant in all null models that fix species
+ (column) frequencies (\code{"c0"}), and all components are constant
+ if row columns are also fixed (e.g., model \code{"quasiswap"}), and
+ the functions are not meaningful with these null models.
+
+}
+
\value{
The result returned by a nestedness function contains an item called
\code{statistic}, but the other components differ among functions. The
@@ -130,6 +154,10 @@
disorder in the distribution of species in fragmented
habitat. \emph{Oecologia} 96, 373--382.
+ Baselga, A. (2010). Partitioning the turnover and nestedness
+ components of beta diversity. \emph{Global Ecol. Biogeog.} 19,
+ 134--143.
+
Brualdi, R.A. & Sanderson, J.G. (1999). Nested species subsets, gaps,
and discrepancy. \emph{Oecologia} 119, 256--264.
More information about the Vegan-commits
mailing list