Is there an existing function to concatenate paths?
I know it is not that difficult to implement, but still… besides taking care of trailing / (or \) I would need to take care of proper OS path format detection (i.e. whether we write C:\dir\file or /dir/file).
As I said, I believe I know how to implement it; the question is: should I do it? Does the functionality already exist in existing R package?
Yes,
file.path()There is also the equally useful
system.file()for files in a package:which will get the file
extdata/date_time_zonespec.csvirrespective ofwhich is very handy. Lastly, there is also
if you insist on doing it manually.