search for: rivulet

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

2012 Nov 29
4
splitting a string by space except when contained within quotes
I've been trying to split a space delimited string with double-quotes in R for some time but without success. An example of a string is as follows: /rainfall snowfall "Channel storage" "Rivulet storage"/ It's important for us because these are column headings that must match the subsequent data. Here is some code I've been trying: str <- 'rainfall snowfall "Channel storage" "Rivulet storage"' regex <- "[^\\s\"']+|\"([^\...