From the course: Complete Guide to R: Wrangling, Visualizing, and Modeling Data

Unlock the full course today

Join today to access over 24,600 courses taught by industry experts.

Importing data from a spreadsheet

Importing data from a spreadsheet

- [Instructor] R's built in data sets are a great way to get started exploring R and seeing what you can do with it, but when it comes time to do actual analysis, you're going to want to bring in your own data, and usually the easiest way to do that is to import a spreadsheet. Spreadsheets are the universal data containers, billions of data sets in the rows and columns of a spreadsheet, and they're very easy to import in R as long as you have what's called tidy data, and that means each column is a variable, each row is an observation, and there's no funny business like merged cells or comments or formulas in there. If you do that, you've got a few different options on how you can import things into R. To do that, I'm going to start by loading up the packages, including rio, which stands for R input output, and it's a way of importing data and exporting. Now, I'm going to import a data set here that is from the exercise files that you downloaded. This right here, if you're in the R…

Contents