Graphing in R & ggplot2 workshop off to a great start!

Thanks to the 30+ CDVG members that came out to the first night of the Graphing in R & ggplot2 workshop at 1871. It was a great start and I look forward to doing more of these in the future. I’ve updated the presentation and posted it to slideshare. Here is a highlight of the changes:

  • added link to a matrix multiplication tutorial on the Matrix: Arithmetic slide (p. 26).
  • changed the data frame subsetting example to access columns by name instead of index number.
  • cleaned up typos.
  • added references page.

Free copy of the R Cookbook for the first person to post and share a valid solution to any one of the exercises on slide number 36. You can post on your own blog, on our CDVG blog (contact me) or Github(recommended). just let us know where you put it.

Another reminder that we don’t have the IMSA classroom on October 22 and we will either push the schedule a week or just meet in the shared areas of 1871. We will make that decision before leaving 1871 this coming Monday.

I look forward to seeing everyone next week when we will start using ggplot2 under the tutelage of Tom Schenk. Bring $5 if you want to have pizza that night. Drinks are BYO. I’ll bring a few extra beers for anyone that wants to do a beer swap. It’s a great way to discover something new to drink.

See everyone Monday.


Thanks,

Josh Doyle
Advertisements

Workshop: Graphing with R & ggplot2

Descriptionggplot2 example by Hadley Wickham

Introduce yourself to R and the powerful graphing library based on the Grammar of Graphics–ggplot2. Attendees will work in small teams to learn how to generate basic and advanced plots in ggplot2 to solve a variety of problems. The workshop will also review the fundamentals of data visualization to increase the readability and clarity of plots.

The workshop is open to all types of users, including those who are unfamiliar with R. We will mix some demonstration with small group-based projects. Basic principles of data visualization will also be emphasized alongside ggplot2 demonstrations to put the program into a larger context.

Audience

The workshop is targeted to individuals who are not familiar with ggplot2, including beginners who are new to the R software. Attendees will need to bring there own computer where we will install the R and ggplot2 software–don’t worry, both are open source and free.

Time, Location, & Signup

The workshop begins October 8  in the IMSA classroom at 1871 located on the 12th floor of The Merchandise Mart (222 W. Merchandise Mart Plaza). It includes four sessions (outline below) meeting on consecutive Mondays at 6pm. The IMSA room isn’t available on October 22 so, depending on the number of attendees, we will either meet in a smaller conference room or push the schedule a week.

There are only 30 seats available for this workshop due to the size limitations of the IMSA classroom. Interested attendees need to go to the CDVG meetup site to sign up for each of the four sessions.

Workshop Leaders

The workshop will be led by CDVG member Tom Schenk. Tom is a Senior Research Data Analyst at Northwestern University, Department of Medical Social Sciences. You can read more about Tom on his website. He also curates Data Nouveau–a collection of interesting data visualizations on the web.

Tom will be assisted by CDVG member Josh Doyle (who is relatively new to R & ggplot2 and will ask the dumb questions so others won’t have to). We also expect to have some other experienced folks in the room to help out.

Workshop Outline

Introduction to R (October 8)

We will familiarized ourselves with the R environment with a gentle introduction to the basic functions. After installing R, we will import and inspect data sets while becoming familiar with R terminology. By the end of the class, we will conduct basic descriptions and plots of the data.

  • Learn how to import data into R.
  • Understand the structure of data sets and their components..
  • Learn how to describe data.
  • Download and install new packages from CRAN.
  • Plot data using basic R functions.

Introduction to ggplot2 (October 15)

We will begin to use the ggplot2 package to create basic, but handsome, univariate, bivariate, and time-series graphs. We will introduce the functions and terminology used in ggplot2. We will also explain the fundamentals of proper data visualization techniques and how it relates to the ggplot2 defaults.

  • Install the ggplot2 package.
  • Use geometric shapes to display data.

Grammar of Graphics (October 22 or 29)

We will continue to show more advanced features of ggplot2, including how it relates to Leland Wilkinson’s Grammar of Graphics. We will show how to plot more than 2 variables in a single graph using colors, shapes, and sizes. We will also discuss how human ability to perceive different shapes and colors should drive the choices we make in data visualization.

  • Using scales to add information.
  • Using coordinates to aid interpretations.
  • Easily create small multiple graphs.

Plots for Publications (October 29 or November 5)

After learning how to make plots, we will learn how to customize graphs with custom colors, labels, and themes. We will emphasize how to create a customized look to be included in publications, including adding labels in diagrams to help readers.

  • Saving graphs from R into publication-friendly formats.
  • Use custom colors for plots.
  • Use your own fonts.
  • Customizing ggplot2 graphs with the new themes feature.