simul.comm: Simulation of ecological data structured by single ecological...

Description Usage Arguments Value Author(s)

Description

Simulation of ecological data structured by single ecological gradient

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
simul.comm(totS = 300, gr.length = 5000, niche.type = "random",
  max.niche.breath = gr.length, min.niche.breath = 10, amplitude = NULL,
  spec.optima = "random", prop.random.species = 0, seed = NULL,
  plotting = F, highlight.species = NULL)

sample.comm(simul.comm = NULL, Np = 300, sample.x = "random",
  no.ind = 100, cv.no.ind = 0.01, k = 0.2, seed = NULL, pa = FALSE,
  based.on = "individuals", standardize.rowsums = TRUE)

## S3 method for class 'simcom'
plot(simcom, xlab = "Gradient", ylab = "Abundance", ...)

## S3 method for class 'samcom'
plot(samcom, xlab = "Gradient", ylab = "Abundance", ...)

Arguments

totS

Total number of species in simulation.

gr.length

Length of the gradient in units.

niche.type

Shape of species response curves ('random', 'normal', 'skewed').

max.niche.breath

Maximum niche breath along the gradient (default = gr.length)

min.niche.breath

Minimum niche breath along the gradient (default = 10). Cannot be more than max.niche.breath.

amplitude

Amplitude of species response curve (height in its optimum). Default is to generate amplitude as random values from lognormal distribution (with meanlog = 2 and sdlog = 1). Can be vector of numeric values; if the vector is shorter than totS, the values are recycled. If all amplitudes should be equal, supply vector of the length one.

spec.optima

Distribution of species optima along simulated gradient. Either one of 'random', 'unimodal' or 'skewed', or a vector (of the length equal to totS) with numbers (ranging between 1 and gr.length). Default = 'random'.

prop.random.species

Proportion of random species, i.e. species which are not related to the gradient. Should be real number from [0,1]. These species are generated by randomizing occurrence of given proportion of species among samples. Default = 0.

seed

Set random seed for reproducing always the same result.

plotting

Should the species response curves along simulated gradient be drawned? Default = FALSE.

highlight.species

Vector of species numbers which should be highlighted by color in ploted diagram (if plotting = TRUE). Default = NULL, which means that if plot is drawned, two species will be highlighted - the most generalized and the most specialized one.

simul.comm

Object created by simul.comm function with parameters of individual species response curves.

Np

Number of samples to be generated.

sample.x

Positions of sampling locations along the gradient. Default = "random", meaning that random locations are generated. Other options include "equal" with samples distributed in equal distances, "biased" with samples accumulated toward higher values of the gradient. Can be also vector of the same length as Np with exact positions of the samples.

no.ind

Mean number of individuals to be sampled from the species pool (if based.on = 'individuals').

cv.no.ind

Coefficient of variation of number of indiduals sampled from the species pool. Increasing it allows to create set of samples with various levels of undersampling.

k

Mean proportion of species from species pool to be drawn into local community (if based.on = 'species'). If only one number is given, in each sample given proportion of species will be sampled from species pool. If vector of two numbers (range of k valus) is given, random k in given range will be generated (with uniform distribution) for each sample; this allows to vary the degree of undersampling among generated samples.

pa

Result table will be generated in presence-absence form (default pa = FALSE).

based.on

Should the sampling of species from species pool be based on 'individuals' or 'species'? (default = 'individuals')

standardize.rowsums

Standardizes the abundances of species in samples so as the sum of species abundances in sample is 100 (standardizes to rowsums equal to 100). Applies only if pa = FALSE. Default = TRUE.

simcom

Object returned by the function simul.comm.

xlab

Label of the x-axis. Default to "Gradient".

ylab

Label of the y-axis. Default to "Abundance".

...

Other parameters passed into plot.

samcom

Object returned by the function sample.comm.

Value

The function simul.comm returns list with 10 items, describing the set of parameters used to simulate community of species response curves:

The function sample.comm returns list of 5 items with parameters of generated community data; the last item contains also all items returned by simul.comm function:

Author(s)

David Zeleny (zeleny.david@gmail.com) - based on the scripts of Jason Fridley (Fridley et al. 2007, Appendix S2) and David Zeleny (Zeleny 2009, Appendix S1)


zdealveindy/theta documentation built on May 4, 2019, 9:13 p.m.