I'm using dplyr and I want to select all the columns on the table but return only the rows where one specific column ends with '006'
.
select(sample_id, ends_with("006"), everything())
The code above doesn't work. When I run it, it returns all rows (or more than I need -- it's a huge dataset).
I've tried using:
filter(sample_id == ends_with('006'))
but ends_with()
needs to be used within a select function.