# Principal Component Analysis

# load the dataset
datos <- iris
# separate numerical inputs
x <- datos[,1:4]
y <- datos[,5]
# calculate components
components <- prcomp(x, center=TRUE, scale=TRUE)
# display components
print(components)
# summarize components
summary(components$x)
# plot the components
biplot(components)
