I would like to know what is the proper way to empty a data frame in R.
I need to keep colnames only.
Example:
id | fruit
---+------------
1 | strawberry
2 | blackberry
3 | apple
4 | peer
would, after the operation, be:
id | fruit
---+------------