If I have a dataframe structure like that:
AA1_123.zip
BB2_456.txt
CCC_789.doc
How can I change it to this:
AA1
BB2
CCC
If I have a dataframe structure like that:
AA1_123.zip
BB2_456.txt
CCC_789.doc
How can I change it to this:
AA1
BB2
CCC
If the strings are all the same style at the start, three characters before the underline, this will work:
You could also read the column again, using
comment.char = "_"
to flush the rest of the line. YOr you can use
scan()
You could try
sub
data