Skip to content

RainbowR 2026 Conference Workshop on LLMs for Data Analysis

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE
Unknown
license-web.qmd
Notifications You must be signed in to change notification settings

thisisnic/rainbowrworkshop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LLMs in R for Data Analysis

rainbowR 2026 Conference Workshop by Nic Crane

Workshop Overview

LLMs can be massively useful in R workflows, when used in the right places and if you're aware of not only the benefits, but also the risks. In this hands-on workshop, you'll learn how to use LLMs programmatically in R, and come away with both the confidence to experiment and a working script that extracts data from unstructured text.

We'll look at where LLMs can help, where they'll let you down, and techniques for making your results more trustworthy. You're going to leave with a practical sense of what's possible and where to be cautious.

What you'll learn:

  • Getting started with LLMs in R using {ellmer}
  • Prompt engineering for more predictable results
  • Extracting structured data from unstructured text
  • Using LLMs to call R functions (tool calling)

Workshop Prework

Option A: Use Posit Cloud (recommended for beginners)

If you'd prefer not to install anything on your laptop - or if you're on a work machine with restrictions on installing software or connecting to external APIs - you can use Posit Cloud instead.

  1. Go to posit.cloud and create a free account
  2. Create a new RStudio project
  3. Follow steps 1-4 below inside your cloud project

This runs R entirely in your browser. Your API key stays in your cloud project, not on your work machine.

Option B: Local installation

1. Install R packages

install.packages(c("ellmer", "mall", "dplyr", "readr", "tidyr", "usethis"))

2. Get an API key

We recommend Gemini (free), but Anthropic or OpenAI work too if you already have credits.

3. Store your API key

Run usethis::edit_r_environ() in R, then add:

GOOGLE_API_KEY=paste-your-key-here
# OR: ANTHROPIC_API_KEY=paste-your-key-here
# OR: OPENAI_API_KEY=paste-your-key-here

Save the file and restart R.

4. Test your setup

library(ellmer)
chat <- chat_google_gemini()  # or chat_anthropic() / chat_openai()
chat$chat("Say hello!")

If you see a greeting back, you're all set!

Workshop Schedule

  • Section 0: Welcome and Setup
  • Section 1: Getting Started with LLMs in R
  • Section 2: Prompt Engineering
  • Section 3: Structured Output
  • Section 4: Tool Calling
  • Section 5: Wrap-up and Resources

Instructor

Nic Crane is an R educator and consultant. They are passionate about open source, and learning and teaching all things R.


Copyright © 2025 Nic Crane. All Rights Reserved.

About

RainbowR 2026 Conference Workshop on LLMs for Data Analysis

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE
Unknown
license-web.qmd

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages