Skip to content
Prev 9005 / 398502 Next

Pattern Matching help

Samir Mishra wrote:
grep("\\.", test.dat, value = TRUE, extended = FALSE)
gsub("\\.", "_", test.dat, extended = FALSE)
Yes. Think about the "." in regular expressions.

Uwe Ligges
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._