Displaying 1 result from an estimated 1 matches for "tellse".
Did you mean:
tells
2006 Jan 05
1
How do I get sub to insert a single backslash?
Something about the way R processes backslashes is defeating me.
Perhaps this is because I have only just started using R for text processing.
I would like to change occurrences of the ampersand & into ampersand
preceded by a backslash.
> temp <- "R & D"
> sub("&", "\&", temp)
[1] "R & D"
> sub("&",