cmdescape
fixes the use of parameters which contain special characters of the terminal (or spaces)- Regression: the updated version does not work with custom specified arguments. If this is desired, there should be an optional list parameter for this purpose.
- Single expressions do not need (and should not have) parentheses. This goes universally (and in particular, since R is a functional programming language, for functions).
- There’s no need to forward
%sed%
tosed
(and same for%grep%
), it can be declared as an alias. In fact, the original function is somewhat redundant since operators can be called as functions. - Use
`…`
instead of'…'
to specify unusual names: the former is syntactically a name while the latter is a string! It only “happens to work” because R has special lookup rules for functions when encountering a string. The same won’t work for other (non-function) objects though.