From the course: R for Data Science: Analysis and Visualization

Unlock the full course today

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

Entering data

Entering data

- [Instructor] Obviously, the reason you started working with RStudio is because you want to get some insights from data but you first have to get your data into R. And the easiest way to do that, meaning the one that has the fewest steps is doing it manually, which works for very small amounts of data. But let me show you some of how this works. To do this, I'm using the file 02_05_EnteringData.R. Now, R can do a lot of things pretty easily. One is it can do basic math. I just wrote two plus two here and then I press Command + Enter if you're on a Mac or Control + Enter if you're on a pc. And what you see down here is it repeats the command two plus two along with the comment that I put next to it. Then it gives the result four. Now, this thing right here next to it, the one is square brackets, that's an index number. If we had several different numbers and if it went to more than one line, you would see different…

Contents