Created
January 11, 2022 21:26
-
-
Save seasmith/4f6b3291c44ae85c8b8d2ba5c4c7799d to your computer and use it in GitHub Desktop.
unused r snippets that i am 'deleting'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
snippet .arr | |
arrange(desc(${1:vars})) | |
snippet .group_sum | |
group_by(${1:vars}) %>% | |
summarize(${2:value} = ${3:expression}) %>% | |
ungroup() | |
snippet .group_mut | |
group_by(${1:vars}) %>% | |
mutate(${2:value} = ${3:expression}) %>% | |
ungroup() | |
snippet .group_arr_mut | |
group_by(${1:vars}) %>% | |
arrange(${2:vars}) %>% | |
mutate(${3:col} = ${4:expression}) %>% | |
ungroup() | |
snippet .group_fil_mut | |
group_by(${1:vars}) %>% | |
filter(${2:cond}) %>% | |
mutate(${3:col} = ${4:expression}) %>% | |
ungroup() | |
snippet .group_fil_arr_mut | |
group_by(${1:vars}) %>% | |
filter(${2:cond}) %>% | |
arrange(${3:vars}) %>% | |
mutate(${4:col} = ${5:expression}) %>% | |
ungroup() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment