Consider the 2 columns that I have below:
SubjID Sample_Type
ABC12 bld
ABC13 bld
ABC14 bld
ABC15 bld
ABC12 bld
ABC12 bld
ABC12 ser
ABC12 ser
ABC13 ser
ABC13 ser
ABC12 urn
ABC15 urn
Now, how do I count the number of unique sample types for each subjID? For example, ABC12 should have 3, and ABC13 should have 2. Thanks.
Bookmarks