Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Programming
- /
- SAS Procedures
- /
- How do I run diversity index calculation on individual replicates for ...

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 06-29-2016 11:17 AM
(1994 views)

Suppose I have the following data in a single column (I've placed it in a row to save space but we alwasy work with it in a column):

2 3 5 6 7 7 8 9 10 10 10 10 10 10 10 10 10 10 20 20 20 20 20 20 20

Each number represents a differents species, and the number of each number represents the number of individuals of that species identified in the sample set (so in the above set there were two individuals of species "7").

I want to take repeatedly sample 10 individuals from the above set, AND THEN run Simpson's/Shannon's diversity index individually on each replicate, AND THEN determine a mean diversity based on the diversity of all individual replicates.

I'm a major beginner at SAS, from what I can tell I have proprietary software 9.3 with enhanced analytical products in the 12.1-12.2 region. I've figured out how to do the repeated sampling using the following:

*********************************

proc surveyselect data = arrival method = urs sampsize = 10

rep = 10 out = my_data;

run;

*********************************

Can someone help me with the rest of the steps please?

p.s. I also don't know if my method of analysis is statistically viable, it is my attempt to compare the genetic diversity of two populations for each of which we have a different number of samples. The different sample sizes prevent direct comparison of genetic diversity, so I thought we could subsample the larger set down to the size of the smaller set. If you have a big sexy statistical brain I would appreciate comments on this idea as well.

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

You should be subsampling your sample sets, not your species. The field sampling method must be the same for both populations for this comparison to be valid.

PG

4 REPLIES 4

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

You should be subsampling your sample sets, not your species. The field sampling method must be the same for both populations for this comparison to be valid.

PG

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

What do you call a sample in which you identify species? It should be something like "setting a trap for 48 h" or "listening to bird calls for 15 m" or "counting bacteria in 10 ul". I.e. it should represent a standardized effort. Otherwise, you can't compare species diversity between sites or populations.

PG

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

**If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. **

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.