Learn R Programming

parfossil (version 0.2.0)

par.nmds: A parallelized function for estimating species diversity

Description

Estimate the diversity of a sample(s) using a number of species diversity estimators.

Usage

par.nmds(dmat, mindim = 1, maxdim = 2, nits = 10, iconf = 0, epsilon = 1e-12, maxit = 500, trace = FALSE)

Arguments

dmat
Lower triangle distance matrix
mindim
optional, the minmum number of dimensions to use for an analysis; default is 1
maxdim
optional, the maximum number of dimensions to use for an analysis; default is 2
nits
optional, the number of iterations; how many times the data should be initially placed at random; default is 10
iconf
optional, initial configuration. If not specified, then a random configuration is used.
epsilon
optional, acceptable difference in stress.
maxit
optional, maximum number of iterations.
trace
if TRUE, will write progress indicator to the screen.

Value

conf : list of configurations.stress : list of final stress values.r2 : total variance explained by each configuration. The first results are for the lowest number of dimensions (total number is (mindim - maxdim + 1) * nits).

Details

Non-Metric Multidimensional Scaling (NMDS) is designed to find an optimal arrangement for a set of points in a reduced dimensional space.

References

The original nmds function used as the basis for this parallelized version comes from the ecodist package.

Goslee, S.C., Urban, D.L. 2007. The ecodist Package for Dissimilarity-based Analysis of Ecological Data. Journal of Statistical Software. 22(7):1-19.

See Also

ecol.dist

Examples

Run this code
## Not run: 
# #comparison of run times between the serial and parallel versions on the estimator
# #please note that this example is designed for a multicore OS X or Linux computer
# library(doMC)
# registerDoMC()
# data(fdata.mat)
# par.nmds(ecol.dist(fdata.mat))
# ## End(Not run)

Run the code above in your browser using DataLab