Two ways to run R code in Google Colab

Опубликовано: 14 Февраль 2026
на канале: Brian Byrne
9,623
89

In this video, we demonstrate two simple ways to run R code in Google Colab, a platform commonly used for Python but which now supports R as well. Google Colab offers a cloud-based environment that makes data science more accessible, and now you can easily run R code in just a few steps.

Using Rmagic: By running the command %load_ext rpy2.ipython and adding %%R at the start of each cell, you can execute R and Python within the same notebook.

or

2 load the following line of code into your browser
https://colab.research.google.com/#cr...

This video makes it easy to set up and run R code in Google Colab, whether you're a beginner or an experienced user.