Calculation of the Shannon Index plotwise or over the entire population Imagine I inventarized a forest with 28 plots. Do I calculate the Shannon-Index for each plot and take the average, or should I calculate the Shannon-Index over the whole population?
I use R and the vegan package. A example for clarification:
 http://txt.do/d0l0l (broken link) is the entire population and http://textuploader.com/d0l0q (broken link) the population divides by subplots.
My code is something like that:
shannon<-diversity(spac, index = "shannon") #plotwise
mean(shannon)

 A: Well, what you should do depends on what is your goal. Are you interested in the biodiversity of the forest itself, measured via sampling 28 plots, then you should use the complete sample and calculate one Shannon-index. But, if your interest is in how the biodiversity varies over the forest, then maybe you should calculate the 28 indices. 
Since you indicate taking the mean of the 28 plot indices, probably you want the former. So I will assume you want one measure of biodiversity of the complete forest. Then, use the complete sample and calculate one index. Especially if the individual plots are too small, they could miss entire species and so not represent well the biodiversity of the forest. If you then calculated 28 separate plot indices and averaged them, you could get a severally biased result, the biodiversity would be underestimated. 
A: also about this kind of problem, but as I am new in bioinformatics, I am trying to use the CSV file importing data to analyse the alpha- and beta- diversity. However some programming knowledge is a shortage for me, would you mind giving me a basic kind of coding for reference so that could help me.
