Calculates individual or sample-based rarefaction (D.A. Murray).

### Options

`PRINT` = string token |
Controls printed output (`summary` ); default `summ` |
---|---|

`METHOD` = string token |
Controls the type of rarefaction (`individual` , `sample` ); default `indi` |

`PLOT` = string token |
Controls plot type (`expected` ); default `expe` |

`SAMPLESIZES` = scalar or variate |
A scalar defining a step between sample sizes or number of samples to estimate the number of species; alternatively, a variate specifing the actual sample size values or number of samples |

`CIPROBABILITY` = scalar |
Probability for the confidence interval; default 0.95 |

### Parameters

`DATA` = variates, matrices or pointers |
For individual-based rarefaction, a variate containing the number of individuals for each species; for sample-based rarefaction, a pointer or matrix specifying the number of individuals for each species for different sites/samples |
---|---|

`EXPECTED` = variates |
Saves the expected number of species at each sample size |

`VARIANCE` = variates |
Saves the variance for the expected number of species |

`LOWER` = variates |
Saves the lower confidence limit at each sample size |

`UPPER` = variates |
Saves the upper confidence limit at each sample size |

### Description

Rarefaction is a method that can be used to estimate the number of species that would be found if sampling effort was reduced to a specified level. This then allows comparisons amongst communities where sampling effort is unequal. For individuals in a sample, individual-based rarefaction can be used to estimate the number of species that would be observed given a smaller number of individuals (Heck *et al*. 1975). Sample-based rarefaction can be used to estimate the expected number of species that would be observed given a smaller number of samples (Colwell *et al*. 2004). Rarefaction assumes that individuals have been sampled randomly and sample-based rarefaction assumes a random sample ordering. The method also assumes that the samples that are to be compared are not obtained by different collecting techniques or from communities that are intrinsically different.

For individual-based rarefaction, the number of individuals for each species is specified in a variate using the `DATA`

parameter. For sample-based rarefaction, the data can be supplied using the `DATA`

parameter either as a matrix where the rows contain the number of individuals for each species and the columns specify the different samples, or as a pointer to variates containing samples for the individuals for each species. The expected number of species and associated variance can be saved using the `EXPECTED`

and `VARIANCE`

parameters respectively. The `LOWER`

and `UPPER`

parameters can be used to save the lower and upper bounds for the confidence interval. The type of rarefaction (individual or sample-based) is specified using the `METHOD`

option. The `SAMPLESIZES`

option specifies the sample sizes or number of samples for which the expected number of species is calculated. A scalar can be supplied to specify a step between each sample size, or a variate can be provided containing the actual sample sizes. By default the expected values are calculated for all possible sample sizes.

The `PRINT`

option controls printed output, with settings:

`summary` |
the expected species richness, variance and confidence limits. |
---|

A plot of the expected number of species and confidence limits can be specified using the `expected`

setting of the `PLOT`

option. The probability level for the confidence intervals can be set by the `CIPROBABILITY`

option; by default 0.95.

Options: `PRINT`

, `METHOD`

, `PLOT`

, `SAMPLESIZES`

, `CIPROBABILITY`

.

Parameters: `DATA`

, `EXPECTED`

, `VARIANCE`

, `LOWER`

, `UPPER`

.

### Method

For individual-based rarefaction the expected number of species in a sample of size *n* is calculated by:

E(*S _{n}*) =

*S*– ( 1 / C(

*n*,

*N*) ) × ∑

_{i}{ C(

*n*,

*N*–

*N*) }

_{i}where *N*_{i} is the number of individuals in species *i* of the unrarefied sample, C(*n*, *N*) is the number of combinations of *n* from *N* and C(*n*, *N*–*N _{i}*) is the number of combinations of

*n*from

*N*–

*N*. The variance, var(

_{i}*S*), is outlined in Heck

_{n}*et al*. (1975).

Sample-based rarefaction is calculated by

t(*h*) = *S*_{obs} – ∑_{j=1…H} { *a _{jh}* ×

*s*} for

_{j}*h*= 1 …

*H*

where *s _{j}* is the number of species found in exactly

*j*samples of a total of

*H*samples,

*S*

_{obs}is defined by

*S*_{obs} = ∑_{j=1…H} { *s _{j}* }

and the combinational coefficients *a _{jh}* are estimated by

*a _{jh}* = ((

*H*–

*h*)! × (

*H*–

*j*)!) / ((

*H*–

*h*–

*j*)! ×

*H*!) for

*j*+

*h*≤

*H*

*a _{jh}* = 0 otherwise

The variance is estimated by

var(*h*) = ∑ { (1 – *a _{jh}*)

^{2}×

*s*– t(

_{j}*h*)

^{2}/

*S*

^{~}

where

*S*^{~} = *S*_{obs} + (*H* – 1) × *s*_{1}^{2} / (2 × *H* × *s*_{2})

Further details of this method are given in Colwell *et al*. (2004).

### Action with `RESTRICT`

If a parameter is restricted the statistics will be calculated using only those units included in the restriction.

### References

Colwell, R.K., Mao, C.X. & Chang, J. (2004). Interpolating, extrapolating comparing incidence-based species accumulation curves. *Ecology*, 85, 2717-2727.

Heck, K.L., van Belle, G. & Simberloff, D. (1975). Explicit calculation of the rarefaction diversity measurement and the determination of sufficient sample size. *Ecology*, 56, 1459-1461.

### See also

Commands for Ecological data.

### Example

CAPTION 'ECRAREFACTION examples','Sample-based rarefaction';\ STYLE=meta,minor POINTER [NVALUES=4] sample VARIATE [NVALUES=6] sample[1...4]; VALUES=!(6,0,1,0,0,0),\ !(0,1,0,4,0,0),!(3,0,0,0,2,0),!(0,5,0,0,0,3) ECRAREFACTION [METHOD=sample] sample CAPTION 'Individual-based Rarefaction',\ !t('Data from Siegel & German (1982). Biometrics, 38, 235-242.',\ 'Distribution of species within families of echinoids',\ 'and bivalves.'); STYLE=minor,plain VARIATE [NVALUES=102] Bivalves; VALUES=\ !(24(1),16(2),9(3),9(4),6(5),6(6),6(7),5(8),\ 2(9),12,4(13),2(14),15,16,3(17),20,22,2(29),35,55,99) VARIATE [NVALUES=40] Echinoids; VALUES=\ !(6(1),2,2,3,3,5,5,6,6,7,9,10,11,11,13,13,14,\ 15,23,24,25,25,26,29,32,33,33,36,36,42,49,58,61,86,134) ECRAREFACTION [PLOT=*] Bivalves; EXP=bexp; LOWER=blow; UPPER=bupp ECRAREFACTION [PLOT=*] Echinoids; EXP=eexp; LOWER=elow; UPPER=eupp PEN 2,4; SYMBOL=0; METHOD=mono; LINE=1 XAXIS [RESET=yes] 1; TITLE='Species' YAXIS [RESET=yes] 1; TITLE='Families' DGRAPH [WINDOW=1] bexp,blow,bupp,eexp,elow,eupp;\ 3(!(1...748)),3(!(1...893)); PEN=1,2,2,3,4,4;\ DESCRIPTION=!t('Expected bivalves'),\ !t('lower 95% confidence bound'),\ !t('upper 95% confidence bound'),\ !t('Expected echinoids'),\ !t('lower 95% confidence bound'),\ !t('upper 95% confidence bound')