1

I want to subset a data frame to only keep lines (samples) that one of the column value starts with "GC" in R. Here's an example:

Species A Species B Species C SYTD Lat  Long
1         5         0         IS14 47.5 -55.4
2         2         1         IS15 47.5 -55.3
0         1         4         GC14 47.6 -55.3
3         2         3         GC15 47.6 -55.2

How to keep all columns but only lines which "SYTD" starts with "GC"?

Mud Warrior
  • 127
  • 2
  • 9

0 Answers0