Installing swirl courses into Cloud?

Hi everyone, I am having trouble installing some specific courses from my university into swirl on Studio Cloud. I do not have access to an own laptop, so I cannot install R and am working in R Studio Cloud exclusively. I am using swirl, which works fine, and I just want to add some specific courses to it.

I have tried installing from my computer using this code w no success:

library(swirl)
install_course_zip("file path here", multi=FALSE)

Also tried installing from url with no success using:

install_course_url("https://courses.edx.org/assets/courseware/v1/8ae5204802d13b0733aa818f36dfc15d/asset-v1:MITx+14.310x+2T2020+type@asset+block/14_310x_Intro_to_R.zip")

What am I doing wrong? Grateful for any help.

Thanks! Joana

Can you specify what is the problem you are having with this? I just tried and it works without problems.

It says permission denied, for some reason. Did you try that specific link and it worked? Could you please specify your entire code? Maybe I'm omitting something.

Thanks a lot!

Yes

I just run your lines of code on RStudio Cloud, nothing else.

Can you post the exact error message you get?

Error in unzip(path, exdir = swirl_courses_dir()) : 
  cannot open file '/home/rstudio-user/R/x86_64-pc-linux-gnu-library/4.0/swirl/Courses/14_310x_Intro_to_R/.DS_Store': Permission denied

This is what I get if I run it.

Could you please go to the Terminal tab and run the following:

ls -lsa ~/R/x86_64-pc-linux-gnu-library/4.0/swirl/Courses/14_310x_Intro_to_R/

My output looks like:

total 88
 4 drwxrwxr-x 15 rstudio-user rstudio-user  4096 Jun  8 13:18 .
 4 drwxrwxr-x  3 rstudio-user rstudio-user  4096 Jun  8 13:18 ..
20 -rw-rw-r--  1 rstudio-user rstudio-user 16388 Jun  8 13:18 .DS_Store
 4 -rw-rw-r--  1 rstudio-user rstudio-user  3683 Jun  8 13:18 .Rhistory
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Base_Graphics
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Basic_Building_Blocks
 4 drwxrwxr-x  3 rstudio-user rstudio-user  4096 Jun  8 13:18 Getting_and_Cleaning_Data
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Looking_at_Data
 4 -rw-rw-r--  1 rstudio-user rstudio-user   246 Jun  8 13:18 MANIFEST
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Manipulating_Data_with_dplyr
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Matrices_and_Data_Frames
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Missing_Values
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Sequences_of_Numbers
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Subsetting_Vectors
 4 drwxrwxr-x  3 rstudio-user rstudio-user  4096 Jun  8 13:18 Tidying_Data_with_tidyr
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Vectors
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Welcome
 4 drwxrwxr-x  2 rstudio-user rstudio-user  4096 Jun  8 13:18 Workspace_and_Files

Depending on what yours is, you might need to uninstall and reinstall swirl.

Hi Josh, is that code correct? I am getting

Error: unexpected '/' in "ls -lsa ~/"

You need to run that in the Terminal tab, not the R console.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.