Hello all,

I have a *.csv file that looks like this (actual file is orders of magnitude
larger):

   site taxa no.ind meadow LMA 2 meadow LCY 1 meadow MSA 2 forest LMA 1
forest LCY 1 forest MSA 1 forest MSX 1

I am interested in, but have failed to create, code that efficiently
converts it to a site-by-taxa matrix or data frame that looks like this:
    LMA LCY MSA MSX Meadow 2 1 2 0 Forest 1 1 1 1

With no repeating taxa names and zeros where a taxon is not listed for a
site.  Any help would be greatly appreciated.

Regards,

Drew Garey
Aquatic Ecoloy Lab Manager
Virginia Commonwealth University

        [[alternative HTML version deleted]]

______________________________________________
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.

Reply via email to