On Wed, May 21, 2014 at 9:25 AM, Jeff Newmiller <jdnew...@dcn.davis.ca.us> wrote: > I tend to view this as enforced training in string escaping. > > One option i have not seen mentioned is the file.choose function, which is > GUI but a little tedious for deep directories.
I also was thinking about that too but note that file.choose() does not work for directories so you need a second command choose.dir() for those. readline(), which the poster mentioned, does work for both cases. If the context of this is writing an R script and you want to paste it into your editor session then any powerful editor has the capability of adding functions to perform such transformations. e.g. http://vim.wikia.com/wiki/Copy_filename_to_clipboard Many other programming languages that support escape sequences in string literals also have a syntax to not interpret the escapes and R really needs that capability too. For example, https://docs.python.org/2.0/ref/strings.html Other usage scenarios where this would be useful are dealing with literal latex text and dealing with text literals containing both single and double quotes. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.