Resources

RStudio Cloud | {rscloud} Package | Instructor View

You can access RStudio Cloud's API to manage space members programatically using the rscloud package. You will need to create client credentials to use the package. To do so, click on your icon/name in the header to reveal the User panel, then click on Credentials. This will take you to the Credentials page of RStudio User Settings, where you can create and manage your client credentials. {rscloud} package repo: https://github.com/rstudio/rscloud ABOUT RSTUDIO CLOUD: RStudio Cloud is a lightweight, cloud-based solution that allows anyone to do, share, teach and learn data science online. Analyze your data using the RStudio IDE, directly from your browser. Share projects with your team, class, workshop or the world. Teach data science with R to your students or colleagues. Learn data science in an instructor-led environment or with interactive tutorials. There is nothing to configure and no dedicated hardware, installation or annual purchase contract required. Individual users, instructors and students only need a browser to do, share, teach and learn data science. We will always offer a free plan for casual, individual use, and we now offer paid premium plans for professionals, instructors, researchers, and organizations. RSTUDIO CLOUD RESOURCES: RStudio Cloud https://rstudio.cloud RStudio Cloud Pricing plans https://rstudio.cloud/plans/instructor RStudio Cloud guide https://rstudio.cloud/learn/guide {rscloud} https://github.com/rstudio/rscloud VIDEO CREDITS: Monitor icon made by xnimrodx from flaticon.com Cloud icon made by Freepik from flaticon.com Tiny Putty Music from Blue Dot Sessions: https://app.sessions.blue/browse/track/52046 ### ABOUT RSTUDIO: RStudio’s mission is to create free and open-source software for data science, scientific research, and technical communication to enhance the production and consumption of knowledge by everyone, regardless of economic means, and to facilitate collaboration and reproducible research, both of which are critical to the integrity and efficacy of work across industries. RStudio also produces RStudio Team, a modular platform of commercial software products that give organizations the confidence to adopt R, Python and other open-source data science software at scale, along with online services to make it easier to learn and use them over the web. Together, RStudio’s open-source software and commercial software form a virtuous cycle: the adoption of open-source data science software at scale in organizations creates demand for RStudio’s commercial software; and the revenue from commercial software, in turn, enables deeper investment in the open-source software that benefits everyone. Check out www.rstudio.com Follow us on Twitter: https://twitter.com/rstudio Facebook: https://www.facebook.com/rstudiopbc/ And LinkedIn: https://www.linkedin.com/company/rstudio-pbc/

image: thumbnail.jpg

Transcript#

This transcript was generated automatically and may contain errors.

As R users, we know that sometimes code is the best way to handle things, and in this video walkthrough, we'll be focused on setting up our access to the rscloud package.

Setting up client credentials

To get started using the rscloud package, we first need to set up our client credentials, and we do this from within RStudio Cloud. After logging in to our RStudio Cloud account, we can click on our icon or photo in the top right to access the user panel, and then select Client Credentials. This will take us to a page with any existing credentials we might have. To create new credentials, click on Plus New Credentials in the top right.

This will open a popup where you can name your credentials. After naming your credentials, click OK to see and copy your generated credentials. You will only be shown the credentials once, so do be sure to copy them and store them in a secure place before closing the popup window. Be careful not to share or commit your credentials to Git.

Configuring the R environment

The recommended method for setting your credentials is by editing your R Environ file, and we can do this using the usethis package. From within RStudio Cloud, we can go to a project, and by running usethis, edit renviron in the console. This should then open your R Environ file, where you can paste and save your client credentials before restarting R.

After setting up your credentials in your R Environ file, you can install the development version of the rscloud package by running the following commands in the console. install .packages remote and remotes install github rstudio rscloud Once this is done, you have the rscloud package available and ready to use in RStudio Cloud.

Using the rscloud package

From here, we can do things like run rscloud underscore space underscore list, which will return a table with all of the spaces available within our RStudio Cloud account, and we can use a space underscore id from this table to look at the number of users and projects. For example, when I run rscloud underscore space using the space id 81721, I can see that there are 327 users and 946 projects within this shared workspace.

For example, when I run rscloud underscore space using the space id 81721, I can see that there are 327 users and 946 projects within this shared workspace.

You can learn more about additional functionality of the rscloud package by visiting the package documentation at github.com rstudio rscloud.