Google Slides About R Programming: How to Build One
In this article
Google Slides is a presentation tool, so "Google Slides about R programming" means building a slide deck that teaches or demonstrates R — you write the slides yourself, then paste R code and output into them. The part most people get wrong: you cannot run R inside Google Slides, so the code has to be executed elsewhere (RStudio, Posit Cloud, or any R console) and brought in as text or images.
Time 45 min · Steps 8 · Level Medium
Build the Deck Slide by Slide
- Open a blank deck. Go to Google Slides in a browser, choose a blank presentation, and set a title such as "Introduction to R Programming" on the first slide.
- Plan 8-12 slides. A short teaching deck works well with one slide each for: what R is, installing it, basic syntax, vectors, data frames, a real example, plotting, and where to learn next.
- Use code-formatted text. Select any R code on a slide and apply a monospace font (for example Courier New) so
x <- c(1, 2, 3)reads clearly against the surrounding prose. - Run the code first. Open R or RStudio, run each snippet, and copy the actual console output — showing real output like
[1] 2 4 6is far more convincing than describing it. - Insert output as images. Screenshots of plots or the RStudio window go in via Insert > Image; crop them tightly so only the plot or console shows.
- Colour-code your snippets. Use a dark background text box for code and a light one for output, so the audience can tell input from result at a glance.
- Annotate the example. On your worked-example slide, add short callout labels naming each part: the function, the argument, the result.
- Share or present. Use Present for a live talk, or Share > Anyone with the link > Viewer so readers can open the deck on their own.
Know What Google Slides Can and Cannot Do With R
Google Slides has no R interpreter, no add-on that runs R, and no live data connection to an R session. Anything dynamic — a chart built from data, a statistical model, a Shiny app — must be produced in R first and brought across as a static image or text. That limitation actually helps you: a deck that shows finished output is easier to present than one that depends on a live environment, and it never breaks mid-talk.
One practical workflow: keep a plain text file of your R snippets open beside the deck. Run a snippet, copy the output, paste both onto the slide, and move on. Menu labels can differ slightly by version, but Insert > Image and Insert > Text box have been stable for years.
Worked Example: A Mean Slide With Real Numbers
Here is a complete slide you can copy. Title: "R in one minute: the mean of five test scores."
Code block (monospace, dark box):
scores <- c(72, 85, 90, 64, 79)mean(scores)
Output block (light box):
[1] 78
Check the arithmetic yourself: 72 + 85 + 90 + 64 + 79 = 390, and 390 ÷ 5 = 78. Showing the hand-check on the slide tells the audience the output is real, not staged. A second line such as sd(scores) (sample standard deviation, which gives about 10.4 for these numbers) extends the same slide into variability without any extra data.
Choose a Slide Order That Teaches R Well
The order that works for most audiences moves from "why" to "what" to "show me":
Slides 1-3: Motivation
What R is used for (statistics, data analysis, graphics), where to get it (the Comprehensive R Archive Network, known as CRAN, and the RStudio desktop editor), and one sentence on the difference between R the language and RStudio the editor.
Slides 4-7: Core Syntax
Assignment with <-, vectors with c(), data frames with data.frame(), and one built-in dataset such as mtcars — it ships with R, so it runs on any machine with no downloads.
Slides 8-10: One Real Analysis
A single worked example carried across three slides: the input data, the command (for example plot(mtcars$wt, mtcars$mpg)), and the resulting scatter plot as an image. One example carried through beats five disconnected ones.
Fix the Problems That Come Up Most
Code wraps badly on the slide. Keep lines under about 60 characters and insert manual line breaks; long pipelines such as %>% chains can be split after the pipe.
Screenshots look blurry. Zoom the RStudio window to 150% before capturing, and paste at or near original size rather than scaling up.
The audience cannot read the code.Body text at 18-24 pt and code at 16-20 pt in a monospace font is the working range for a room presentation; test the deck on a phone screen before assuming it is readable.
Output pastes with odd line breaks. Paste as plain text (Paste without formatting in Google Slides, where available in your version) and reapply the monospace font.
Where to Send People Who Want to Learn R After the Deck
Close the deck with a "next steps" slide listing free, stable resources: CRAN's own "An Introduction to R" manual, the swirl package that teaches R inside the R console, and Posit Cloud, which runs RStudio in a browser with nothing to install. A rule of thumb worth putting on that final slide: one hour a day for a few weeks is enough to move from never having used R to doing your own data frames and plots — and a deck that shows a real worked example, with output you verified by hand, is what makes that believable.
Official source: Google Workspace Learning Center