I’ve always been interested in what sort of tools that academics use to get their job done. There are a plethora of ways to analyze data, to acquire research papers, etc.
So, Kaggle posted a nice dataset that I wanted to play around with.
This data is really tough to work with. For each of the tool variables it has two options for example, the SPSS variable.
If the respondent uses it the dataframe has a value of “SPSS”, if not there is a missing value. That can’t be used to make bar charts because each positive value will be different. I have got to make some conversion.
CAR Package
The way that I am most comfortable with comes from Stata, and that’s just a bunch of recodes. That’s really labor intensive.
That get’s me where I want to go, but that takes a lot of syntax.
Apply
The beauty of R is that there are many ways to get where you want to go. I asked this question on my Kaggle Script and got two other approaches. One was apply.
##DPLYR
Hadley’s terrific dplyr package can also do the same thing in a little different way.
Overall, I wanted to put these syntax examples up so that I have a record of how to do each of them for future analysis.