Performing dimension reduction with Principal Component Analysis (PCA)
Principal component analysis (PCA) is the most widely used linear method in dealing with dimension reduction problems. PCA is useful when data contains many features and there is redundancy (correlation) within these features. To remove redundant features, PCA maps high-dimension data into lower dimensions by reducing features into a smaller number of principal components that account for most of the variance of the original features. In this recipe, we will introduce how to perform dimension reduction with the PCA method.
Getting ready
In this recipe, we will use the economic freedom dataset as our target to perform PCA. The economic freedom (http://www.heritage.org/index/ranking ...
Get R for Data Science Cookbook now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.