For this assignment, I will be working with data based off the 2016 Presidential Election. The data consists of three variables: Name, ABC poll results, and CBS poll results. Upon further analysis of the data, one can see that the Name variable is of type character while the poll result variables are of type numeric.
At the beginning, the data looks something like this:
Immediately, one can see that this data may be a bit easier to read if put into a data frame.
To place the data into a data frame, one can use the following piece of code:
Executing this piece of code, the data frame will look like the following:
Taking a look at the data frame via str(election), there are 7 observations for the 3 variables.
You can look at the code in its entirety by clicking the GitHub link below:
~ Katie
No comments:
Post a Comment