We're glad you are still with us.
Please review our Help Menu options. Make sure you know what's there.
The first link is link to other links online we found helpful
The second link details the datamentor.io R programming page and their Tuturial . It offers cliff notes for that too!
Please go to the DM.io Tutorial Summary link on hour help menu now and spend 15-30 minutes reviewing all that information!! That is really the beginning of Session 3!
If you have not reviewed the DM.io Tutorial Summary referenced just above, do that first. Very important.
Our next lesson is about importing data and "attaching it" to the environment.
We got this insight from this video to the right.
https://www.youtube.com/watch?v=WWY8VPh6ryo
Unfortunately this video is older. The Import link she uses to open that page no longer exists. I found that out in the notes (and by looking at my own interface with confusion). We'll show you were to click to get the import going below.
On 10/2/2019, the 'import dataset" button was located on the Environment Tab.
When we clicked on it, this is what we saw...
When clicked:
From Text (base) simply asks you to open a file. No clue what type it takes or wants..
From Text (readr) opens a window similar to that in the video. You pick a file, and looks like it wants delimited data, like CSV. We'll use this below.
From Excel opens a comparable window as From Text, but it expects you to pick an Excel file.
Didn't try the others yet...
When we selected From Text(readr) the first time, it went through about a 2-3 minute setup process. Seemed like a one time thing.
After that, when we select Text(reader) this window comes up and when a CSV file is selected, this is what we sawafter it brought that data in. Review the settings and options in the bottom of the window. This is a data preview.
NOTE: With the CSV file, if you export that from Excel, if the data does not start in cell A1 it has issues.
Note the name in the bottom left is "dataSet1". That will become that variable name for this dataSet on import. You can change that here or assign it to another variable in a moment.
If we select 'Import" on the bottom right, this window disappears, and is what we see next.
Per the video, we need to attach(dataSet1) to get it to become usable, so we did that and got a few red notes spit back at us. Not exactly sure why.
Then we tried to access the data in the column, just to see if we understand how to grab a little data with that $ trick we learned in the tutorial and it seems to work. Note, when I accidentally typed in dataset1 instead of dataSet1 I got a "not found" error
when we give it the plot command, it works!!! Yahoo
With the CSV file, if the data does not start in cell 1, it has issues. It seems to be a little smarter with Excel files. it will find the data on the page, In this case the data was starting in A3
Also note, in bottom left area, you can select which "sheet" and even which "range" you want to import from.
Given these advanced import features, if your data is in excel it's a lot easier to import from Excel than to export to CSV and then import.
You now understand the difference between R and Rstudio.
You understanding basic R programming in RStudio
You understand or at least have the gist of the different data structure formats in R
You know how to import data and attach it for use.
You know how to plot.
You now have all the "basic" education you need to start using RStudio and learning on your own!
Well done!!