The correlation tool is used to investigate linear relationships between variables. In this recipe, we will use the example from the Oxford weather station and check the correlation between the mean maximum temperature, mean minimum temperature, air frost days, rainfall, and hours of sunlight.
The data from the Oxford weather station can be obtained from the Met office website at http://www.metoffice.gov.uk/climate/uk/stationdata/.
Open the Oxford weather (cleaned).mtw
file. This is available on the Packt Publishing website. For more on importing this data directly, see the Producing a graphical summary of data recipe.
The following steps will generate the Pearson correlation coefficient and P-value for the results of the weather station data:
The output generates a table that compares all of the variables to one another. The top number is the correlation score and the lower number the P-value. Correlation scores range from -1 to +1, and a score of 0 indicates no correlation. The null hypothesis for this test is that there is no correlation; the alternative is that there is correlation. Strong correlations should be seen between the temperature columns and hours of sunlight.
With a lot of variables, the correlation table can often be wider than the page width of the session window. The results are then displayed across multiple output tables. The session window's output width can be changed in Options… under the Tools menu.
Correlations can also be visualized very quickly using a matrix plot. This chart will plot a scatterplot of each variable versus one another.
Spearman Rank correlation is also available in Minitab v17 by changing the Method: option to Spearman rho.
3.145.17.18