Problem loading Manipulating Data with dplyr module in the Getting and Cleaning Data course
I have tried to install in swirl and from my hard drive and I get the same error message: Attempting to load lesson dependencies...
| Package ‘dplyr’ loaded correctly!
Error in yaml.load(readLines(con, warn = readLines.warn), error.label = error.label, : (C:/Users/daniellec/OneDrive - Lacerta Therapeutics, Inc/Documents/R/R-4.1.2/library/swirl/Courses/Getting_and_Cleaning_Data/Manipulating_Data_with_dplyr/lesson.yaml) Scanner error: while scanning a tag at line 205, column 9 did not find expected whitespace or line break at line 205, column 19
| Leaving swirl now. Type swirl() to resume.
Here is the systemInfo
sessionInfo() R version 4.1.2 (2021-11-01) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 22000)
Matrix products: default
locale: [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 LC_MONETARY=English_United States.1252 [4] LC_NUMERIC=C LC_TIME=English_United States.1252
attached base packages: [1] stats graphics grDevices utils datasets methods base
other attached packages: [1] dplyr_1.0.9 swirl_2.4.5
loaded via a namespace (and not attached):
[1] rstudioapi_0.13 magrittr_2.0.3 tidyselect_1.1.2 R6_2.5.1 rlang_1.0.2 fansi_1.0.3
[7] stringr_1.4.0 httr_1.4.3 tools_4.1.2 sessioninfo_1.2.2 utf8_1.2.2 DBI_1.1.2
[13] cli_3.3.0 ellipsis_0.3.2 assertthat_0.2.1 yaml_2.3.5 digest_0.6.29 tibble_3.1.7
[19] lifecycle_1.0.1 crayon_1.5.1 brio_1.1.3 purrr_0.3.4 vctrs_0.4.1 bitops_1.0-7
[25] RCurl_1.98-1.6 testthat_3.1.4 curl_4.3.2 glue_1.6.2 stringi_1.7.6 compiler_4.1.2
[31] pillar_1.7.0 generics_0.1.2 pkgconfig_2.0.3
I am using a Dell OptiPlex 7080 with 64 gigs RAM
I hit the same error. Here is how I got around it.
Execute the step in the instructions 'install_from_swirl("Getting and Cleaning Data")'.
Then edit the file lesson.yaml. Replace lines 203 thru 205 with the following. (My version of lesson.yaml is attached as lessonbn.yaml.txt.) lessonbn.yaml.txt
CorrectAnswer: '!is.na(c(3, 5, NA, 10))'
AnswerTests: omnitest('!is.na(c(3, 5, NA, 10))')
Hint: \!is.na(c(3, 5, NA, 10)) will negate the previous command, thus telling us what is NOT NA.
You will notice that line 203 has the example in single quote marks and in line 205 the bang (!) is escaped with a backslash (\).
Save the file and continue with the rest of the instructions.
You might have to start swirl() more than once to get past the function deprecation message. This tells me the lesson needs to be edited to work with R Studio 4.1.2.
Thank you very much! That works well!
Thanks for this issue, I'll work on addressing it.
Thank you very much! That works well!
CorrectAnswer: '!is.na(c(3, 5, NA, 10))' AnswerTests: omnitest('!is.na(c(3, 5, NA, 10))') Hint: !is.na(c(3, 5, NA, 10)) will negate the previous command, thus telling us what is NOT NA.
This was a great helps, thanks!