diff --git a/snippets/r.snippets b/snippets/r.snippets index c7ca5ac..bcc6733 100644 --- a/snippets/r.snippets +++ b/snippets/r.snippets @@ -25,7 +25,7 @@ snippet ei # functions snippet fun - ${1:name} = function (${2:variables}) { + ${1:name} <- function (${2:variables}) { ${0} } snippet ret @@ -39,7 +39,7 @@ snippet c snippet li list(${0:items}) snippet mat - matrix(${1:data}, nrow=${2:rows}, ncol=${0:cols}) + matrix(${1:data}, nrow = ${2:rows}, ncol = ${0:cols}) # apply functions snippet apply @@ -100,7 +100,7 @@ snippet pl snippet ggp ggplot(${1:data}, aes(${0:aesthetics})) snippet img - ${1:(jpeg,bmp,png,tiff)}(filename="${2:filename}", width=${3}, height=${4}, unit="${5}") + ${1:(jpeg,bmp,png,tiff)}(filename = '${2:filename}', width = ${3}, height = ${4}, unit = '${5}') ${0:plot} dev.off()