We’ve been learning about different aspects of R – how to bring data in, how to clean the data, and how to graph the data. Providing us with the basics of manipulating our data and visualizing it. Remember though that R is a system that is used for statistical computation as well as graphics. What makes is a robust system is that it includes a programming language, graphics, interfaces or connection opportunities with other languages, and debugging capabilities. Although we can use R for many different purposes we can also use it for our statistical needs.
To start the statistical side of things, today we will see how we can use R to create correlations and regressions with our data. We will use Fisher’s Iris dataset as the sample data to take us through correlations and regressions.
Let’s work through the R script file in R Studio. I will add tricks and tips that I’ve learned in the sample at a later date. Please note that the R-script file contains comments throughout to guide you through it.