I am new to R so I apologize in advance. I sampled moths along an elevational gradient with a total of 8 different sites. I had unequal sampling nights per elevation. Because of my unequal sampling nights, I want to standardize my species by rarefying my species based on the individuals I got. I am confused about how to rarefy my species data. From the rarefy package (rarefy(x, sample, se = FALSE, MARGIN = 1), I don't understand how to specify my sample/subsample number. Is it going to be the minimum number of individuals I got from a site? Thank you very much
Asked
Active
Viewed 466 times
1 Answers
1
Yes, to account for uneven sampling you would typically rarefy to the minimum number of individuals you got from a site. Below is an example:
library(vegan)
data(BCI)
# Your data should be organised like the BCI data - species in columns, sites in rows.
# Use rowSums to find the minimum number found at a site:
raremax <- min(rowSums(BCI))
# Rarefy to that number
rarefied_data <- rrarefy(BCI, raremax)
This gives you a table in the same format (species x site) where all the rows sum to the same number.
Note there are other ways to deal with uneven sampling, and some people think rarefying needlessly throws away data. The following papers are discussing microbial communities, but the arguments are still relevant for moths:
https://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1003531 https://www.biorxiv.org/content/10.1101/2020.09.09.290049v1.full

rw2
- 1,549
- 1
- 11
- 20
-
Thank you very much – Pal Feb 15 '22 at 17:24
-
2I have always (and this means a *long* time) thought that (random) rarefaction is a weird thing to do. If I would not care about modern literature, I would at least read carefully I.J. Good (1953) The population frequencies of species and the estimation of population parameters. Biometrika 40, 237 –264 and then rethink about (random) rarefaction and throwing away data on species frequencies. And don't forget Turing who saw all this a decade earlier! – Jari Oksanen Feb 20 '22 at 00:56