Escape \ns

It seems need to double escape "\n" for R now i.e. '\\\\n' in the perl!