On 10/08/2013 10:21 PM, Elaine Kuo wrote:
Dear list
I have a matrix composed of islandID as rows and speciesID as columns.
IslandID: Island A, B, C….O (15 islands in total)
SpeciesID: D0001, D0002, D0003….D0100 (100 species in total)
The cell of the matrix describes presence (1) or absence (0) of the species
in an island.
Now I would like to search how many species are found in (1, presence) for
Island A, Island D, and Island L respectively.
Please kindly advise the R code for the search purpose.
Hi Elaine,
Sounds like "rowSums" to me.
Jim
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.