[R] Transforming data
Jeff Reichman
re|chm@nj @end|ng |rom @bcg|ob@|@net
Thu May 6 21:36:50 CEST 2021
R Help Forum
I am attempting to transform the data frame in Table 1 to the form shown in
Table 2. Any suggestions. I�ve started by removing duplicate rows
Jeff
Table 1
Taxon
Importer
Guarouba guarouba
AE
Acipenser gueldenstaedtii
AE
Caiman crocodilus fuscus
AE
Caiman crocodilus fuscus
AE
Caiman crocodilus fuscus
AE
Ara ararauna
AG
Ara chloropterus
AG
Python reticulatus
AE
Strombus gigas
AE
Strombus gigas
AE
Strombus gigas
AE
Strombus gigas
AE
Strombus gigas
AE
Varanus niloticus
AE
Varanus niloticus
AE
Caiman crocodilus fuscus
AE
Table 2
Country
Guarouba guarouba
Acipenser gueldenstaedtii
Caiman crocodilus fuscus
Python reticulatus
Strombus gigas
Varanus niloticus
Caiman crocodilus fuscus
Ara ararauna
Caiman crocodilus fuscus
AE
1
1
1
1
1
1
1
0
0
AG
0
0
0
0
0
0
0
1
1
[[alternative HTML version deleted]]
More information about the R-help
mailing list