search for: the_new_instance

Displaying 1 result from an estimated 1 matches for "the_new_instance".

2008 Nov 26
1
How to create a string containing '\/' to be used with SED?
...ke: command <- paste("sed -i 's/^instance .*/instance = ", data$instancePath, data$newInstance, "/' ", configurationFile, sep = "") system(command) This will overwrite the line starting with "instance " using "instance = the_new_instance" In the example I gave, data$instancePath = /home/TSPFiles/TSPLIB/ and data$newInstance = berlin52.tsp The problem is that I need to pass the above path string to sed in the form: "\/home\/TSPFiles\/TSPLIB\/" However, I couldn't find a way to "create" such a string...