From f1a073e7427df1f635f5247dd81a66d1428531a3 Mon Sep 17 00:00:00 2001 From: hpolvech <helene.polveche@ens-lyon.fr> Date: Thu, 14 Oct 2021 11:11:02 +0200 Subject: [PATCH] correction r balises --- session_4/session_4.Rmd | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/session_4/session_4.Rmd b/session_4/session_4.Rmd index 4ef3102..feeb7a6 100644 --- a/session_4/session_4.Rmd +++ b/session_4/session_4.Rmd @@ -314,10 +314,12 @@ select(flights, contains("_") & !starts_with("sched") & !starts_with("time")) ``` </p> </details> -- What does the `one_of()` function do? Why might it be helpful in conjunction with this vector? +- What does the `one_of()` function do? Why might it be helpful in conjunction with this vector? + ```{r select_one_of, eval=T, message=F, cache=T} vars <- c("year", "month", "day", "dep_delay", "arr_delay") ``` + <details><summary>Solution</summary> <p> ```{r challenge_select_b, eval=FALSE} @@ -325,6 +327,7 @@ select(flights, one_of(vars)) ``` </p> </details> + - Does the result of running the following code surprise you? How do the select helpers deal with case by default? How can you change that default? ```{r select_contains, eval=F, message=F, cache=T} select(flights, contains("TIME")) -- GitLab