Activity 3.3 - PCA implementation

SUBMISSION INSTRUCTIONS

  1. Render to html
  2. Publish your html to RPubs
  3. Submit a link to your published solutions

Problem 1

Consider the following 6 eigenvalues from a \(6\times 6\) correlation matrix:

\[\lambda_1 = 3.5, \lambda_2 = 1.0, \lambda_3 = 0.7, \lambda_4 = 0.4, \lambda_5 = 0.25, \lambda_6 = 0.15\]

If you want to retain enough principal components to explain at least 90% of the variability inherent in the data set, how many should you keep?

# 3.5 + 1.0 + 0.7 + 0.4 + 0.25 + 0.15 = 6
#we would want to keep at least 4 of the eigenvalues 
#Which would give us a total of .9333 and which is 93.3% the 
#is the least amount possible of added eigenvalues being higher 
#than 90%

Problem 2

The iris data set is a classic data set often used to demonstrate PCA. Each iris in the data set contained a measurement of its sepal length, sepal width, petal length, and petal width. Consider the five irises below, following mean-centering and scaling:

library(tidyverse)


five_irises <- data.frame(
  row.names = 1:5,
  Sepal.Length = c(0.189, 0.551, -0.415, 0.310, -0.898),
  Sepal.Width  = c(-1.97, 0.786, 2.62, -0.590, 1.70),
  Petal.Length = c(0.137, 1.04, -1.34, 0.534, -1.05),
  Petal.Width  = c(-0.262, 1.58, -1.31, 0.000875, -1.05)
) %>% as.matrix
five_irises
  Sepal.Length Sepal.Width Petal.Length Petal.Width
1        0.189      -1.970        0.137   -0.262000
2        0.551       0.786        1.040    1.580000
3       -0.415       2.620       -1.340   -1.310000
4        0.310      -0.590        0.534    0.000875
5       -0.898       1.700       -1.050   -1.050000

Consider also the loadings for the first two principal components:

# Create the data frame
library(factoextra)
Warning: package 'factoextra' was built under R version 4.5.2
Welcome! Want to learn more? See two factoextra-related books at https://goo.gl/ve3WBa
five_irises_pca <- prcomp(five_irises, scale. = TRUE)
  
five_irises_pca
Standard deviations (1, .., p=4):
[1] 1.7834925 0.8249853 0.3505249 0.1252439

Rotation (n x k) = (4 x 4):
                    PC1        PC2        PC3        PC4
Sepal.Length -0.5352000 0.06795288  0.8343787  0.1129407
Sepal.Width   0.3901261 0.86525013  0.2113644 -0.2333858
Petal.Length -0.5537354 0.10055074 -0.2570335 -0.7856211
Petal.Width  -0.5047175 0.48643002 -0.4393985  0.5617606
fviz_pca(five_irises_pca, axes=1:2)
Warning: Using `size` aesthetic for lines was deprecated in ggplot2 3.4.0.
ℹ Please use `linewidth` instead.
ℹ The deprecated feature was likely used in the ggpubr package.
  Please report the issue at <https://github.com/kassambara/ggpubr/issues>.

#both five_irises_pca and pc_loadings yield the same thing

pc_loadings <- data.frame(
  PC1 = c(0.5210659, -0.2693474, 0.5804131, 0.5648565),
  PC2 = c(-0.37741762, -0.92329566, -0.02449161, -0.06694199),
  row.names = c("Sepal.Length", "Sepal.Width", "Petal.Length", "Petal.Width")
) %>% as.matrix

pc_loadings
                    PC1         PC2
Sepal.Length  0.5210659 -0.37741762
Sepal.Width  -0.2693474 -0.92329566
Petal.Length  0.5804131 -0.02449161
Petal.Width   0.5648565 -0.06694199

A plot of the first two PC scores for these five irises is shown in the plot below.


Match the ID of each iris (1-5) to the correct letter of its score coordinates on the plot.

#Iris 1
#PC1 = 0.189(0.52)-1.97(-0.269)+0.137(0.58)-0.262(0.565) = 0.559
#PC2 = 0.189(-0.377)-1.979(-0.924)+0.137(-0.0245) = 1.763
# Iris 1 = (0.559,1.76)

#Iris 2
#PC1 = 0.551(0.52)  + 0.786(-0.269) + 1.04(0.58) + 1.58(0.56) = 1.563
#PC2 = 0.551(-0.377) + 0.786(-0.924) + 1.04(-0.0245) + 1.58(-0.067)
#= -1.065
#Iris 2 = (1.563, -1.065)


#Iris 3
#
#PC1 = -0.415(0.52) + 2.62(-.269) - 1.34(0.58) - 1.31(0.565)
# = -2.44
#PC2 = -0.415(-0.378) + 2.62(-0.924) + 1.04(-0.0245) + 1.58(-0.067)
#= 2.45

#Iris 3 = (-2.44,-2.39)


#Iris 4
#
#PC1 = 0.31(0.52)-0.59(-.269) + 0.534(0.58) + 0.00088(0.56)= 0.630
#
#PC2 = 0.31(-0.378) -0.59(-0.924)+0.534(-0.245) + 0.00088(-0.066) = #.2965
#
#Iris 4 = (0.63, 0.2965)

#Iris 5
#
#PC1 = -0.898(0.52) + 1.7(-0.269) - 1.05 (0.58) - 1.05(.565) = -2.1265
#
#PC2 = -0.898(-0.3) + 1.7(-0.924) - 1.05 (-0.0245) - 1.05(-0.067)
# = -1.135
#
#Iris 5 = (-2.13, -1.14)

#1-5 member that
# point a = iris 3
# point b = iris 1
# point c = iris 4
# point d = iris 2
# point e = iris 5

Problem 3

These data are taken from the Places Rated Almanac, by Richard Boyer and David Savageau, copyrighted and published by Rand McNally. The nine rating criteria used by Places Rated Almanac are:

  • Climate & Terrain
  • Housing
  • Health Care & Environment
  • Crime
  • Transportation
  • Education
  • The Arts
  • Recreation
  • Economics

For all but two of the above criteria, the higher the score, the better. For Housing and Crime, the lower the score the better. The scores are computed using the following component statistics for each criterion (see the Places Rated Almanac for details):

  • Climate & Terrain: very hot and very cold months, seasonal temperature variation, heating- and cooling-degree days, freezing days, zero-degree days, ninety-degree days.
  • Housing: utility bills, property taxes, mortgage payments.
  • Health Care & Environment: per capita physicians, teaching hospitals, medical schools, cardiac rehabilitation centers, comprehensive cancer treatment centers, hospices, insurance/hospitalization costs index, flouridation of drinking water, air pollution.
  • Crime: violent crime rate, property crime rate.
  • Transportation: daily commute, public transportation, Interstate highways, air service, passenger rail service.
  • Education: pupil/teacher ratio in the public K-12 system, effort index in K-12, accademic options in higher education.
  • The Arts: museums, fine arts and public radio stations, public television stations, universities offering a degree or degrees in the arts, symphony orchestras, theatres, opera companies, dance companies, public libraries.
  • Recreation: good restaurants, public golf courses, certified lanes for tenpin bowling, movie theatres, zoos, aquariums, family theme parks, sanctioned automobile race tracks, pari-mutuel betting attractions, major- and minor- league professional sports teams, NCAA Division I football and basketball teams, miles of ocean or Great Lakes coastline, inland water, national forests, national parks, or national wildlife refuges, Consolidated Metropolitan Statistical Area access.
  • Economics: average household income adjusted for taxes and living costs, income growth, job growth.

In addition to these, latitude and longitude, population and state are also given, but should not be included in the PCA.

Use PCA to identify the major components of variation in the ratings among cities.

places <- read.csv('C:/Users/lr7273ow/OneDrive - Minnesota State/Documents/GitHub/DSCI_415/Activities/Data/Places.csv')
head(places)
                       City Climate Housing HlthCare Crime Transp Educ Arts
1                 AbileneTX     521    6200      237   923   4031 2757  996
2                   AkronOH     575    8138     1656   886   4883 2438 5564
3                  AlbanyGA     468    7339      618   970   2531 2560  237
4 Albany-Schenectady-TroyNY     476    7908     1431   610   6883 3399 4655
5             AlbuquerqueNM     659    8393     1853  1483   6558 3026 4496
6              AlexandriaLA     520    5819      640   727   2444 2972  334
  Recreat Econ      Long     Lat    Pop
1    1405 7633  -99.6890 32.5590 110932
2    2632 4350  -81.5180 41.0850 660328
3     859 5250  -84.1580 31.5750 112402
4    1617 5864  -73.7983 42.7327 835880
5    2612 5727 -106.6500 35.0830 419700
6    1018 5254  -92.4530 31.3020 135282
places_num <- places %>% select('Climate','Housing','HlthCare',
                                'Crime','Transp','Educ','Arts','Recreat','Econ')

A.

If you want to explore this data set in lower dimensional space using the first \(k\) principal components, how many would you use, and what percent of the total variability would these retained PCs explain? Use a scree plot to help you answer this question.

places_pca <- prcomp(places_num, scale. = TRUE)

places_pca
Standard deviations (1, .., p=9):
[1] 1.8461560 1.1018059 1.0684003 0.9596446 0.8679199 0.7940793 0.7021736
[8] 0.5639490 0.3469900

Rotation (n x k) = (9 x 9):
               PC1        PC2          PC3         PC4        PC5         PC6
Climate  0.2064140  0.2178353 -0.689955982  0.13732125 -0.3691499  0.37460469
Housing  0.3565216  0.2506240 -0.208172230  0.51182871  0.2334878 -0.14163983
HlthCare 0.4602146 -0.2994653 -0.007324926  0.01470183 -0.1032405 -0.37384804
Crime    0.2812984  0.3553423  0.185104981 -0.53905047 -0.5239397  0.08092329
Transp   0.3511508 -0.1796045  0.146376283 -0.30290371  0.4043485  0.46759180
Educ     0.2752926 -0.4833821  0.229702548  0.33541103 -0.2088191  0.50216981
Arts     0.4630545 -0.1947899 -0.026484298 -0.10108039 -0.1050976 -0.46188072
Recreat  0.3278879  0.3844746 -0.050852640 -0.18980082  0.5295406  0.08991578
Econ     0.1354123  0.4712833  0.607314475  0.42176994 -0.1596201  0.03260813
                 PC7         PC8           PC9
Climate  -0.08470577 -0.36230833  0.0013913515
Housing  -0.23063862  0.61385513  0.0136003402
HlthCare  0.01386761 -0.18567612 -0.7163548935
Crime     0.01860646  0.43002477 -0.0586084614
Transp   -0.58339097 -0.09359866  0.0036294527
Educ      0.42618186  0.18866756  0.1108401911
Arts     -0.02152515 -0.20398969  0.6857582127
Recreat   0.62787789 -0.15059597 -0.0255062915
Econ     -0.14974066 -0.40480926  0.0004377942
fviz_eig(places_pca)
Warning in geom_bar(stat = "identity", fill = barfill, color = barcolor, :
Ignoring empty aesthetic: `width`.

#ScreePlot should appear: 
#We would use k=3 judging by the Scree Plot 
#PC1 = 36%, PC2 = 13%, PC3 = 12%, PC4 = 10.5%, PC5 =7.5%,  
#PC6 = 6.5% , PC7 = 5.5%, PC8 = 3.5% , PC9 = 1.5%
#In total this would explain ~61% of the variability for 
#these PC values.  
#
#

B.

Interpret the retained principal components by examining the loadings (plot(s) of the loadings may be helpful). Which variables will be used to separate cities along the first and second principal axes, and how? Make sure to discuss the signs of the loadings, not just their contributions!

loadings  
function (x, ...) 
x$loadings
<bytecode: 0x000001d187b9e0e8>
<environment: namespace:stats>
#reference line is placed at 100*1/p, 8.333% for us 

#first dimension contributions
fviz_contrib(places_pca, choice = 'var', axes = 1) + 
  theme_classic(base_size = 8) +
  labs(x = 'Variable',
       title = 'Contribution to first dimension')

#interpretion: For the first principal axes the variables that 
#contribute the most to PC are Arts, Healthcare, housing,  #Transportation, and  Housing. 
#As all loadings are >0, generally cities with more robust arts, #HC housing & transportation will have large PC1 values and cities with #less of those aspects  will have smaller PC1 values   
#

#second dimension contributions

fviz_contrib(places_pca, choice = 'var', axes = 2) + 
  theme_classic(base_size = 8) +
  labs(x = 'Variable',
       title = 'Contribution to second dimension')

#interpretion: For the second principal axes the variables that #contribute the most to principal components are Education, Economy Recreation, and Crime. 

#As all loadings are >0, generally  cities with those higher #metrics will have a larger PC2s and cities with metrics that 
#are lower than that would have smaller PC2s.  

C.

Add the first two PC scores to the places data set. Create a biplot of the first 2 PCs, using repelled labeling to identify the cities. Which are the outlying cities and what characteristics make them unique?

places_pca$x
                PC1           PC2           PC3          PC4           PC5
  [1,] -1.040179917  0.8937689684  1.4366540694  0.509834129 -5.651365e-01
  [2,]  0.439813596  0.0750661769 -1.1547165398 -1.112207185  9.968838e-01
  [3,] -1.875539260  0.0697916922  0.0733467565 -0.046231622 -6.795244e-01
  [4,]  0.910741419 -1.8175821509  1.0961471968  0.573580789  7.690800e-01
  [5,]  2.149247536  0.3288580786  0.0197383504 -1.031501541 -2.385498e-01
  [6,] -1.787961101 -0.7812016710  0.0608349850  0.464818648 -8.239929e-01
  [7,] -1.055448363 -1.0759557980 -0.4259539611  1.320925920 -3.345121e-01
  [8,] -0.648321022 -0.7594404445  0.4080465874  0.231162972 -2.439728e-02
  [9,] -1.804240224 -1.2134764019 -0.9165071462  0.062613595  4.964370e-01
 [10,] -0.499566965  0.1022860267  0.3720736793 -0.095466883 -8.783725e-01
 [11,]  2.973047786  2.0152753943 -2.3577097808  2.016339571  1.877389e-01
 [12,]  0.447705316  2.2268258039  2.7026712755  0.003548290  2.066703e+00
 [13,] -2.325173499 -0.8097023812 -1.2695267539 -1.083594618 -4.792700e-01
 [14,] -1.815471687 -0.8181536195 -0.8550138336 -0.397388971 -1.344734e+00
 [15,]  1.869943160 -1.0859874353 -0.5100809574  0.589741006 -2.856285e-01
 [16,] -2.006028933  0.6188154454 -0.7375681985 -1.335312324 -7.002503e-01
 [17,] -1.053951634 -0.3685144988  0.4031678212  0.446434184  1.182311e+00
 [18,] -0.258106267 -0.8754437800 -0.8913924642  0.406310285 -3.665069e-02
 [19,] -1.486790794  0.0652703329 -0.7139992448  0.122698736 -1.308464e+00
 [20,]  3.025009160 -0.9309766612  0.3140421736 -0.620456023 -7.202042e-01
 [21,]  1.369138378  3.0489754270  1.2270895184  0.391703994 -1.266965e+00
 [22,] -1.026998436 -0.8345920434  0.0751086783  0.382249568 -1.204280e+00
 [23,] -0.495600609  0.6627356544 -0.5833553117 -0.174722298  9.384964e-01
 [24,]  0.002451547  0.1314013049  1.8302323410  1.099735952 -8.798192e-01
 [25,] -0.455759052  1.4519459096  0.3164655016 -0.799710538 -1.082017e+00
 [26,]  4.297358823 -0.9680198888  0.8235468853 -1.309209666 -3.571231e-01
 [27,] -0.335278286 -0.7723509525  0.4531611272 -0.218725953  1.249516e+00
 [28,] -0.478998124  1.0922358463  1.2219587439 -0.729185411 -1.035486e+00
 [29,] -1.122352286 -0.2677294227 -0.7341054547 -1.475207783  2.625089e-01
 [30,] -0.982173269  0.6330713237  1.1193550156 -0.658556383 -7.215045e-01
 [31,] -1.830739805 -1.0811695729 -2.2034771761  0.087515367  7.874943e-01
 [32,] -0.076348081  0.8415054047 -2.2550829013 -0.270128168  6.030321e-01
 [33,] -1.511882599 -0.0162004424 -1.2284915896 -1.272745700 -5.696155e-01
 [34,]  2.819651817 -1.0367095954  0.0379058203  2.607211774 -3.529655e-01
 [35,] -0.035454028 -0.2835524455  0.9905653200  0.036511400  1.136500e+00
 [36,] -1.373428901  0.8480378737 -0.3449391296  0.083767901 -1.660390e-01
 [37,] -0.419610952 -0.8311277762 -0.0699921763  1.093860974  6.516072e-01
 [38,]  0.267406582 -0.8149842215 -0.4290206999 -0.786474240 -7.369178e-01
 [39,] -1.577584052 -0.7562501398  2.1611457443  0.513335884  1.975477e+00
 [40,] -1.282610879 -0.2423605423 -0.7519446360  0.489382350 -1.972359e-01
 [41,] -0.222897558 -0.4010209535  0.5332265895  0.351468133  9.216684e-01
 [42,] -0.377734026  0.1285719676 -0.8793145247 -1.081142630  9.888063e-01
 [43,]  6.301057205 -1.6087416195  0.3626613303  0.276039697 -1.732851e-01
 [44,]  2.030150765  2.1142645523  1.0982432454 -0.260283954  2.557876e+00
 [45,] -0.919912986  1.1220269904  1.6519986824  0.556145376 -3.994833e-01
 [46,] -1.446961762  0.3236541676  0.6167768984  0.744083772  2.020609e-02
 [47,] -1.132861573  1.4759648078 -2.1152166694  1.248330978 -6.148680e-01
 [48,]  2.253046457  0.6479565276 -0.1336535036  2.218149977 -6.921827e-01
 [49,] -0.873193216  0.0695816941  0.3060300564  1.405842520  2.800143e-01
 [50,] -0.147814843  1.0354392546  0.7105650661  0.154568381 -1.285398e+00
 [51,] -1.613062603  1.0226046210  0.0722909843 -1.400508720  9.683344e-01
 [52,] -0.738116993  0.8289868408  2.3180053961  1.327332957 -7.591204e-01
 [53,]  1.876472768 -1.1020733947 -0.1624560449 -0.388952788  1.931283e-01
 [54,] -2.001245392  0.1334736650 -0.7702964268  0.592827036 -1.273164e+00
 [55,]  1.619313300 -0.6211817386  1.7723036867  0.882772256  2.559644e+00
 [56,] -1.291003494 -0.5776695187 -0.6352114598  0.149163466  7.867106e-02
 [57,] -0.991952481  0.9697085136  0.9156212026  0.150074754  5.844215e-01
 [58,] -0.959352041 -0.5209828377  0.2346267168 -0.371049330  9.859082e-01
 [59,]  0.740169004 -0.7295567338  0.6455885962 -0.344109837  6.503480e-01
 [60,]  0.985103642  0.0632051452  0.1813138141 -0.913800204 -6.978233e-01
 [61,] -0.462647669 -0.8413176541 -0.4767477325  0.298646101 -2.282923e-01
 [62,]  0.692940740 -0.4029771952  0.1232062532 -0.600253766 -9.372382e-01
 [63,]  1.083025898 -0.9923045178  0.3192343247  1.255769966  9.732006e-02
 [64,] -1.537912402  0.0013030207 -0.9351684111 -0.902695485 -4.346655e-01
 [65,]  6.464911513 -3.0871344634  0.3916691774 -0.390163164  5.136286e-01
 [66,] -0.365756207 -0.2184209571 -0.2747246486  0.506189161 -4.299635e-01
 [67,]  1.823558457 -0.6502657615 -0.2283638592 -0.600839125  3.664458e-01
 [68,] -1.707934635  0.2732411411 -0.6200200641 -0.193731283  1.214058e-01
 [69,]  3.590349692 -0.8685391854 -0.3047822252 -1.304009984  1.094234e+00
 [70,] -0.016946617  1.7057485941  1.1922295947  0.684315404 -2.112229e-01
 [71,] -0.395038071  0.1121517557 -0.4318838950 -0.693372994 -3.803449e-01
 [72,]  0.641097089 -0.2159941249  0.5565729601 -1.281441314 -6.793186e-01
 [73,] -1.585037998 -0.5203912940 -0.3078887501 -0.363753173 -4.589915e-01
 [74,]  0.905758517 -0.4660740592 -0.1609962083 -0.391643497 -2.856211e-01
 [75,] -0.565657681  0.8018217307  1.9380493700 -0.498658175 -2.714447e-01
 [76,] -1.294851099 -2.0140779298 -0.4492421184  1.126514515 -2.737946e-01
 [77,]  3.416023434  0.1194977433  1.8473482926  0.019965744 -8.427859e-01
 [78,]  1.496120491  0.1541749823 -0.0706576166  3.082428247 -6.980783e-02
 [79,] -2.238668749 -1.6920972451 -0.5941302408  0.644334815 -3.980786e-01
 [80,] -0.589746288 -0.5075009816  0.2642739147 -0.001210338  5.038755e-01
 [81,]  0.601432820 -1.1352336229 -0.3833743810 -0.879145053 -7.029129e-01
 [82,]  0.522570367  2.3305852750  0.4985493196 -1.034544654  6.938928e-01
 [83,] -1.391476934 -0.6139962025 -0.3856772249 -0.525176932  5.704099e-02
 [84,]  3.436432307 -0.0439973814  1.5780852910 -0.153143149  3.951040e-01
 [85,] -0.137247862 -0.0453513063  0.5086807610 -0.816169134  6.529417e-01
 [86,]  3.007985470 -1.4005755538 -0.4478319928 -1.668401663 -6.999493e-01
 [87,] -2.788850085  0.1865804914  0.8060559754 -0.653247143 -3.652821e-01
 [88,] -1.626253811 -0.9298225173 -0.4701747133 -0.128221884  1.008644e+00
 [89,] -1.013280577 -1.2205780414  0.9180871806 -1.489816708  3.012189e+00
 [90,] -0.354497511  0.3863967011  0.7055971735 -0.959059033  2.820046e-01
 [91,] -1.723810234 -1.3785299292  1.3872074370  0.627799006  9.367789e-01
 [92,] -0.779384424  0.5404239047 -0.5219209696 -0.968813691 -1.083794e+00
 [93,] -1.935696209 -0.8972802456 -0.8359898962 -0.287245442  4.685350e-01
 [94,] -1.350998399 -0.9611960904  0.0002077480  0.414236753  3.391358e-01
 [95,] -1.423390619  1.0712923234  1.8857501205  1.378285210 -9.395224e-01
 [96,] -0.785028346 -0.7310352720 -1.1048643286 -0.415507507  6.991830e-01
 [97,]  0.924567974 -0.3285519572 -2.4425106519 -0.656114377  1.176291e+00
 [98,] -0.927742412 -0.2010330320 -0.2140741782 -0.104187902 -2.658170e-01
 [99,] -0.414404058  0.6598649535 -1.2888712243 -0.300119882  5.301198e-01
[100,] -1.200782011 -1.0281175705  2.0753697112 -0.408603186  2.396448e+00
[101,] -0.743120580 -0.8372680340  0.2756704404 -0.290187090 -1.269241e+00
[102,] -1.690979831  0.0005907947 -1.0171181867 -0.382329173  6.757519e-01
[103,] -1.811597388 -0.5132943419 -0.3313783957  0.936152686 -5.101781e-01
[104,] -0.434976344  0.1224507484 -0.6552440286 -2.349990475 -7.505750e-01
[105,] -2.647107466 -0.3470137914 -1.1284918643  0.174165645 -4.167216e-01
[106,] -0.454038805 -0.9136579226  0.2647429578 -0.762460613 -1.239316e+00
[107,] -0.008926587  2.4662668038  0.0624661005  0.428496786  1.909639e+00
[108,]  1.169234664  2.0328784439  0.7022069839  0.127874246 -4.772434e-01
[109,]  0.196715263  1.7030661949  1.7297954939  0.257391304  2.411706e+00
[110,]  0.147871441  1.8476309153  1.2466899731  1.221604275 -1.708198e+00
[111,] -1.648197622 -0.7038907860  0.0112337800  0.003771603  1.448531e-01
[112,] -1.202826764  0.4796633254  0.1952957783  1.042731155  3.601467e-01
[113,] -0.543706494 -1.1495937959 -0.4624248417 -0.778572528  7.923244e-01
[114,]  0.771035770  1.3086580391  0.8857714843 -0.607820872 -2.935065e-01
[115,]  0.438983094  2.1103299468 -0.1464348754 -1.228904009  3.673806e-01
[116,] -2.915406867 -0.5249730258 -0.9657170387 -0.532429289 -8.670018e-01
[117,]  0.294335650 -0.3573786846  1.5096642719 -0.748458596 -1.561334e+00
[118,]  0.745018303  1.3858143864 -0.7638321474 -0.174851495 -5.286291e-01
[119,] -0.019104976 -0.6955616606 -0.6073372807 -1.614274099  9.679423e-01
[120,] -2.005779893  0.1324959965 -0.2185848327  0.412691659  4.437660e-01
[121,] -1.359401405 -1.5463445924  2.4069078079  0.070344120  2.210552e+00
[122,] -0.421146433 -0.1508640723 -0.3477710270 -0.373457991  2.689403e-02
[123,] -1.193684956 -0.2847595693  0.1849629306 -0.481645524  8.991261e-01
[124,] -1.533506792 -0.1493441136  0.1133623455  0.706733531 -1.274421e+00
[125,] -0.985858301 -0.1401518964  0.6701549724  0.311549515  1.168934e+00
[126,]  0.474364209 -0.8438092159 -0.3392123552 -0.042358014 -6.686091e-01
[127,]  0.107965814 -0.8094790496 -0.3544558132 -0.226152898 -1.431861e+00
[128,] -1.014265267 -0.9254736357 -0.7913481776  0.478860491  2.458299e-02
[129,] -0.654014002 -0.3244322358 -0.6683619334 -0.085280912 -1.201042e-01
[130,]  0.777714215 -1.7094216359  0.1587551487  0.452312868  4.007942e-01
[131,]  2.841498806 -1.0678545999  1.3107158216  0.772930677 -9.158056e-02
[132,] -1.591834023 -0.5570818264 -1.0223634068  0.271086059 -9.718650e-01
[133,]  2.852693232  1.9587873235 -2.1940715926  0.833846426  2.249297e+00
[134,] -2.295279541  1.9056383901  0.1614259863  0.518941988  1.230987e+00
[135,]  2.542645150 -0.1443598915  2.2116779865  0.356226223 -1.091542e+00
[136,] -1.411462574 -0.6789210392 -1.3566686949 -0.261663217 -3.379005e-01
[137,] -1.641163476  1.1086729844 -0.1890151454 -0.031807099 -9.597740e-01
[138,]  0.913949333 -0.6915407515 -0.1743520123 -1.028315805  2.052348e-01
[139,] -0.143782787 -0.7225153272  0.1254730691  0.617519732 -7.896495e-02
[140,] -0.907538310 -0.4003152850 -0.7102741450 -1.367314352  5.164845e-01
[141,]  0.234196891 -1.3075994552  1.0157800687 -0.420572444 -2.077339e-01
[142,]  0.736185407  0.1994573767  1.3386945793 -0.871775197  5.662144e-01
[143,] -1.645540834  0.6689821467  0.2299041674  0.412294351 -1.332706e+00
[144,] -1.519325473 -0.1437082560 -0.4914794288 -0.539547233  2.731121e-01
[145,]  0.794695307 -0.1299943868 -0.5773021811 -1.090112711 -1.082649e+00
[146,] -0.945220069 -0.5644249161 -1.2448083161  0.650776511 -2.377255e-02
[147,] -1.818434460 -1.4042801260 -0.9546048898  0.124894560  4.888806e-01
[148,] -0.155296457 -0.7135191942 -0.2136744076 -0.006476892  5.536689e-01
[149,] -2.144020746 -0.6955699540 -0.3035271631  0.539650038 -1.023711e+00
[150,]  0.267514273 -0.2588083193 -0.0556060821 -0.850009369  3.994711e-01
[151,] -1.261079098 -0.1899635718  0.4724950057  0.126513263 -5.558775e-01
[152,]  0.300609866 -0.4206203037  0.7039314670  0.236159603 -8.638062e-01
[153,]  1.326162169 -0.5369119182  0.1769276282 -1.576517813 -4.300604e-01
[154,]  0.189459223 -0.2625097811  0.0811443277 -0.125257215  5.224746e-01
[155,] -1.636740887 -0.8583209175  1.6817945356  0.957400509 -5.104952e-01
[156,] -0.136304940  0.1826676294 -0.8480414182  0.077259847  4.427467e-01
[157,] -2.400148068 -1.6306996074 -1.2579937799  0.455312292 -1.288805e-01
[158,] -0.249259085 -0.8530447380  1.3392242299  0.090169971  1.514288e+00
[159,] -0.756692250 -1.2588016726 -0.4402182663  0.112128515  1.161798e+00
[160,] -0.235148127  2.5418515685  2.7428978624  0.736993210  2.916426e-01
[161,] -1.321323238  1.1455084826  0.3910520800 -0.790211883  9.050998e-02
[162,]  0.567438070  1.0862627050 -0.5021519525  1.126657722  1.011968e+00
[163,] -0.756593873  0.3638580978  1.7519923831 -0.965508536  1.793354e-01
[164,] -0.767142325 -1.2634119909 -0.4233660747  1.321235954  1.596615e-01
[165,]  0.169262721 -1.0508051464  0.1010502082 -0.528745668  4.768529e-01
[166,] -1.785447307 -0.5741965433  0.7600013435 -0.315652190 -8.192794e-01
[167,] -0.584895721  0.6420042361  0.0404601481 -0.875392764 -1.251302e+00
[168,]  1.353918406  3.3390658270  0.1828274574 -2.319467506  9.971674e-01
[169,] -0.950459822 -0.0375245488 -0.4839526051 -0.507212971 -2.329400e-01
[170,] -0.115852380  1.2566669339 -0.0002504346  0.718769839  1.882096e-01
[171,] -1.620933450  1.2146712091  0.5051276322 -0.696178217 -6.036392e-01
[172,] -1.437945994 -0.3370601246 -0.4991633274 -0.310924914  2.814937e-01
[173,]  0.509445200  0.0949211545 -0.0572174038  0.425730071 -9.746250e-01
[174,] -1.210020121 -0.5004419438 -0.6256020323 -0.659610165  1.503919e-01
[175,] -0.140374837 -0.9270082916  0.5617637950 -0.413749555  1.099361e+00
[176,] -0.124098823  0.0788571087  0.2360221533 -1.048698165 -6.326765e-01
[177,] -1.514362018  0.3852203272  1.0805483345  0.703895202 -1.232717e+00
[178,] -1.026801795 -0.8928302614 -1.8609096335 -0.349354260  5.684939e-01
[179,]  7.246306536  0.4771515803 -2.0509604581 -0.521696948 -1.654810e+00
[180,]  0.983547598 -0.8749401550 -0.1371456662 -0.330285800 -2.067197e-01
[181,] -0.529882249  0.7086036529  0.2831353801  0.814460262 -1.390528e-01
[182,]  0.059249463  1.2110048233  0.1148270814 -1.285834133 -1.249274e+00
[183,] -0.781136026 -0.5789755208 -0.8642534303  0.036966771  1.303222e-01
[184,] -1.698175209 -0.1839914141  0.5203824190 -0.006000655 -1.961439e-01
[185,]  1.143900899 -1.2527127375  0.9756006258  0.194647207  1.210928e+00
[186,] -0.929356822  0.1238007233  1.4084073175  1.397064506  4.184284e-01
[187,] -1.469106588 -0.3902180940 -0.5909373517 -0.354912150 -9.233015e-01
[188,] -2.571686179 -0.4236744573  1.7672617759 -0.241109214 -8.343125e-02
[189,] -1.104669236 -0.5881410182 -1.6599309514  0.105381686  1.159849e-01
[190,]  0.202005574  2.3234564914  0.3665581817  0.553723412  5.118348e-01
[191,]  1.198265913 -0.2962242103  0.5004241416 -1.739084364 -2.207986e-01
[192,]  3.645810330  2.5415409775  0.2144873707 -2.354817822 -6.580152e-01
[193,]  2.138280360 -1.3204639246  0.3556664311  2.286232506 -3.065678e-01
[194,]  0.361534525  0.0605042923 -0.0304728381  1.875755186  3.981253e-01
[195,] -0.109814201  3.0299920524  2.0758214041  1.043322181 -6.066798e-01
[196,]  2.184615414 -1.0469823285  0.0417455684  0.038739259  1.126268e+00
[197,]  2.507248428 -1.7350778629  1.6410449147 -0.116234985  8.913500e-01
[198,] -0.216975517  0.0689148217  0.3158868711 -1.563271090 -5.375858e-01
[199,] -1.439367888  0.6680429723 -1.0127462337  0.254783127 -1.507023e+00
[200,]  1.924454384  1.0836248381 -0.7611519619  1.068709503  6.814585e-01
[201,] -1.601709733  0.4216801440  0.3854731513 -0.705122154  4.107739e-02
[202,] -1.700796146 -0.1274850781 -0.2905686930 -0.525036368 -1.678581e-05
[203,] -0.915501549 -1.4732925856 -0.5347401804 -0.646745560 -3.443334e-02
[204,] -0.513184852  0.6824480893 -1.0362048616 -2.105908964 -3.664298e-01
[205,] -0.538836210  0.5997101369  0.2111469864  2.031784603  4.279191e-01
[206,]  0.671290065 -0.0149533988 -0.0255247836 -0.164094416 -1.662213e-01
[207,]  2.946730439  0.3793679451 -0.1636385730  2.404810299  1.802600e-01
[208,] -1.160888237  0.7554973696 -1.2016448131 -0.293862975 -5.005325e-01
[209,]  0.385536769 -0.2600892304  0.7831885025  1.264185018 -1.621321e-01
[210,]  2.258781297 -1.4958314836  0.0569105628  1.120544509 -4.078815e-02
[211,]  0.369196092  0.2436905637  0.3815197136  1.711903358  5.582059e-01
[212,]  2.616924972  0.8365438953  1.0949415008 -0.981630598 -1.224739e-01
[213,] 12.426251147 -2.0617460861 -0.2097639247 -3.425504448 -1.683149e+00
[214,]  4.132770101 -0.7897233000 -0.2781058050  1.166169677 -1.492668e+00
[215,] -0.780953311 -0.1314393449 -0.7671909008 -0.796960263  1.011697e+00
[216,]  1.382180387  0.3424708781 -0.3986811903  0.310216002 -2.061513e-01
[217,]  3.019501409  0.8843188975 -1.2952909458  3.712374892  8.989124e-01
[218,]  3.246729602  1.4749262856 -2.2374165617 -0.257326548 -5.962533e-01
[219,] -0.268388958  1.3927747341  2.2999119401 -0.635390109  5.185907e-01
[220,] -0.971997666  1.8937719945  1.0878766373  0.046644704 -2.782269e+00
[221,]  0.908428971  0.9448187975  1.7261467382  0.309382491 -1.177544e+00
[222,] -0.920410965  0.3238527384 -1.6178607116  0.233449911 -2.115658e-01
[223,]  1.078036201 -1.0717413529  1.1990622711 -0.409067762  2.747246e-01
[224,]  0.431748718  0.0481072034 -0.0663515905  0.754491795  1.284765e-01
[225,]  1.356902473  1.5510684319  2.1300857181 -0.883261677  1.044304e-02
[226,] -2.060541497  0.1137039314 -0.0292069820  0.789569458 -5.014728e-01
[227,]  0.308977159  2.4690767924 -3.2809079967  1.525550908 -1.824429e-01
[228,] -1.137343929  1.5729765815  0.3342386278 -0.837378239 -7.078346e-01
[229,] -1.582997518 -0.2558048108 -0.8732825736  0.166237089  2.602704e-01
[230,] -2.734257138  1.3814032334 -1.8776690777 -0.863079130  5.919470e-01
[231,] -0.066552905 -0.6324370265 -0.4237379339  0.755617655  1.759741e-01
[232,] -0.323760908  0.9222380151  0.6576978512 -0.662661741 -1.125635e+00
[233,] -1.050849920 -0.0907650501 -0.9354947272 -0.613976172  2.283385e-01
[234,]  4.765369525 -3.0732870109  0.3403941160  0.368191602 -1.241219e+00
[235,]  1.247352153  0.6110247035  0.7156925762 -0.144732501 -1.176434e-01
[236,] -2.328380865 -0.2733962990 -0.2989958086 -0.913861205 -1.253486e+00
[237,]  2.693925457 -2.4559071366  0.0451966969  0.570284090 -2.310166e-02
[238,] -0.851106885 -1.0529782220  0.5031059023  1.011081043  2.024418e-02
[239,]  0.589016770  0.5264021393  0.7612342190 -0.033984856  1.470820e+00
[240,]  2.467508585 -0.2015712907 -1.2234729333 -0.617481475 -6.952797e-01
[241,] -0.934516289  0.7957995426  1.6070162561  2.885528244 -1.679639e-01
[242,] -0.576269691  0.4281088429  0.7463489716  1.439686221  5.739553e-01
[243,]  2.202165505 -1.5281266145  0.0671466372  0.421161548 -1.112113e-01
[244,] -0.620540452 -0.0481740491 -1.4525091426 -0.526745472  2.519144e+00
[245,] -1.179267217  0.0971542142 -0.1483144689 -1.026546814 -3.583837e-01
[246,] -0.522795065  0.0422063022 -0.5038010452 -0.445350989  2.693390e-01
[247,]  2.617910746 -1.5745293826  0.5722120171  0.625969811 -7.187513e-01
[248,] -0.738745854 -0.5836337330 -0.4857437422  1.179134439 -2.542739e-01
[249,] -0.279812333  0.6932078486 -1.4789150762 -0.892306878  1.070178e+00
[250,]  0.984607755  1.2255976698 -0.1427555570 -0.246199353  1.495931e+00
[251,] -1.676412990  1.6144836018 -1.5970106947 -0.682490492  5.025051e-01
[252,]  1.789639853 -0.5845509941  0.2975100949 -0.432089289  1.217265e-01
[253,]  0.935860107  0.6369608863 -0.9183071230 -0.676404011 -1.022512e+00
[254,] -0.446353738  0.2276890922 -0.8961576140  0.085225556  1.182741e-02
[255,] -0.707366043 -0.1914132665  0.8471991502  0.340590633  1.613990e+00
[256,]  2.037262743 -0.9863801410  0.9609952798  0.797605773  1.506781e-01
[257,] -1.294895844 -0.3489104518 -0.0885024599 -0.531702169 -7.819838e-01
[258,]  1.021281204  0.6652183864 -0.2189459168 -0.672182213  2.507469e-02
[259,] -0.746578522 -0.4263697345 -0.8788019068 -0.956904937  1.892273e-02
[260,] -1.933760744 -0.8428929481  1.5594348957 -0.028479129  2.065655e+00
[261,] -1.632658076 -0.0687877254  0.8529409578  0.111501200 -8.824480e-01
[262,]  3.007573511 -1.6050819583  1.1427357422 -0.628361005 -3.098463e-01
[263,]  0.227147517 -0.8749171975 -1.5345554363 -0.112997391 -4.051303e-01
[264,]  0.332024183  0.7938366076 -0.8550904696  1.811989911  6.680356e-01
[265,]  1.081569762  2.8736178897 -2.4079626919  0.693525274  6.133861e-01
[266,]  1.460431009  1.0867656743 -0.7158263198 -1.441610670  2.294948e+00
[267,] -1.368365354  1.0633336477  1.5889250003  0.600014958 -1.080283e+00
[268,]  0.334341238 -0.1702653530  2.0275892402 -0.363256990 -2.707915e-01
[269,]  3.671532029  1.4035739680 -2.5850001096  0.757812318  3.877212e-01
[270,]  7.391403335  1.2269996575 -1.6917520499  0.405878082  7.540136e-01
[271,]  2.941028664  1.9059958401 -1.4255298536  2.119846592 -3.481713e-01
[272,]  2.217329528  2.3914801357 -2.2417471584  1.177185378  1.097541e+00
[273,]  1.339691866  1.2548373556 -2.4212610096  1.183735936 -5.908094e-02
[274,]  0.837390215  1.3313183082 -1.6133476571  1.331939039 -1.052948e-02
[275,] -0.220045548  1.6740042596  1.7428988111  0.760836671  8.168824e-01
[276,]  0.449565135  1.1098601619  0.3836261377 -2.081595146 -1.119413e-01
[277,] -0.800026018 -1.6964756247 -0.4344424809  1.017136567 -9.272532e-03
[278,]  3.984144085  1.5872698704 -1.4438363467 -0.896254633  1.372201e+00
[279,] -2.018894766 -1.4506587242 -1.1618315623  0.890589141 -3.087455e-01
[280,] -1.874359954 -0.5096140122 -0.3249257121  0.383187514  8.723539e-01
[281,] -2.006500370  0.5318678177  0.4697613384  0.152252187 -1.397588e+00
[282,] -0.020998176  0.0795414014  1.1282523481 -0.244414251 -8.793290e-01
[283,] -1.428175811 -0.9064478906  0.3928981067 -0.623997296  5.947472e-01
[284,] -1.050510671 -1.1552057178  1.2821023336 -0.312838906  1.823251e+00
[285,] -0.173951448 -0.5210158700  0.1444209535 -1.032242509  8.934960e-02
[286,] -0.505244322 -0.5725972153 -0.4442025774 -0.686382843  2.610308e-01
[287,]  0.871040814 -0.8183811814  0.5897335743 -0.595807788 -2.393459e-01
[288,]  0.735081350 -1.3803399754  1.2417937967 -0.234295162 -1.964399e-01
[289,] -0.952244166  0.3073787554  0.2423045935 -0.142821100 -1.827209e-01
[290,]  3.446100098  1.0882629727 -1.6573994838  4.241358734  4.790755e-01
[291,] -1.131627620 -1.1249372946 -0.7446942881  1.220693706 -3.244613e-01
[292,] -2.448180688 -0.8019987418 -1.4693901551  0.306738780  1.076434e-01
[293,] -0.618844628  1.8470024259 -0.6186957939 -1.135156618 -4.384300e-01
[294,]  1.048285277 -1.1762269508 -0.2847332899 -0.641186512  1.638877e+00
[295,]  1.039320162  1.8583950928 -2.0183535386 -1.299358744  6.923612e-01
[296,] -0.194762435  0.3392566864  1.2995214655 -0.643825073  5.632620e-01
[297,]  1.496376278  0.9343353293  2.1108799038 -0.782991160  8.882755e-02
[298,] -1.496721395 -1.2297092180 -0.5674673233 -0.060970447 -1.584945e-01
[299,] -2.224217774 -0.9699875654  0.1345319151  0.039646610 -8.590648e-01
[300,]  0.504344969 -0.8523797367 -0.2459803063 -0.826521094  3.689091e-01
[301,] -0.423723574 -0.5582363371  0.4625704706 -0.449539977 -1.461725e-01
[302,]  1.466178931 -0.3085620654 -0.0876214354  0.768819387 -7.892528e-01
[303,]  1.201631848  1.5080046043  0.1054618668 -0.833862320  6.273364e-02
[304,]  0.243700871  0.9624957255  0.8760176041  0.085741617 -4.179792e-01
[305,] -1.388784942 -0.0989231959  0.0426958959 -1.148995998  5.570225e-02
[306,] -0.785314361 -0.3251808495  1.6739480187  1.424524751 -1.435590e+00
[307,] -1.109752988 -0.8331476097 -0.1969798070  0.540308118  7.581940e-01
[308,]  0.373554968  1.2538817455 -1.8470568872  0.643884468 -6.814220e-01
[309,] -0.922542201  0.7219517905 -2.3579250313  0.040187437 -1.286153e-01
[310,] -1.609867667  1.1392007124  2.2766846621  0.527753347 -5.417515e-01
[311,] -0.459364272  0.0739008570 -0.5591743649 -0.546974843 -6.754636e-01
[312,] -1.121699569  2.1636706115 -0.5073634653 -1.026708216  5.966782e-01
[313,] -1.282513803  0.1209613519  1.4073046440 -0.170772814 -8.865454e-01
[314,]  6.186471306 -2.2648738359  0.3755029458  0.656883134 -6.926983e-01
[315,] -0.724988532 -0.2542213348 -0.3128804706  1.537463903 -8.363090e-01
[316,] -0.999466360 -1.0358365250  0.3398301137 -0.115211821  8.659347e-01
[317,] -1.775715867 -1.2326275562  0.3332060846  0.065288057  1.387935e+00
[318,]  2.202577803  2.4942207082  2.0672389594 -0.088105627  9.562868e-02
[319,] -1.823472525 -1.2765601645 -0.6313246792  1.055725829  3.644746e-03
[320,] -0.297222242 -0.0485009750  0.8747912982 -0.125492909 -7.260855e-01
[321,] -1.340332781  0.6518888706  1.3445797566  0.098035429 -1.144667e+00
[322,] -1.886648755 -1.8550174252 -1.4851673414  0.324224773 -1.075207e-01
[323,]  0.861239719 -0.0907550428  0.3773917804  0.194923459 -6.518782e-01
[324,] -0.009016499  0.8636193206  0.0219563700 -0.853276269 -6.896661e-01
[325,] -0.140982910 -1.6421427275 -0.2308773281  1.224201924 -6.707108e-01
[326,] -1.132623689  0.7398300628 -0.3193301771 -1.115427958  9.981600e-02
[327,] -1.708200900 -0.9049330486 -0.6579820220  1.340778799 -3.117929e-01
[328,] -0.765311001 -1.0753262803 -0.9621526246 -0.435825450 -5.757572e-01
[329,] -1.725960474  0.7303397379 -1.0761048262 -0.551422192 -1.017898e+00
               PC6           PC7          PC8           PC9
  [1,]  0.49785424 -0.4237513406 -1.001775696  0.3474043931
  [2,] -0.62854651 -0.0118948797 -0.418745776 -0.1216854762
  [3,] -0.71409672 -0.2394940320  0.441896961 -0.0942008814
  [4,]  1.27123652 -0.4587161793 -0.371496190  0.3172765960
  [5,]  1.28422401 -0.1545440403 -0.148264110 -0.3071534133
  [6,]  0.09922526  0.5635621223 -0.189355853  0.0733415140
  [7,]  0.24983142  0.4283001698  0.101429093  0.4890170885
  [8,]  0.69034786 -0.4393347113 -0.634448321  0.0079426001
  [9,]  0.48276245 -0.2123054635 -0.453446151  0.1977937595
 [10,]  0.95393250 -0.7680148465 -0.512041125  0.0963279487
 [11,]  0.18993444  0.0764010470  0.234855870 -0.2206125700
 [12,] -1.08664646 -0.4055541419  1.167619859  0.1017333908
 [13,] -0.54433881 -0.1429887161  0.353583875 -0.0627651325
 [14,]  0.02724106 -0.0101783790  0.157248507 -0.1760650120
 [15,] -0.44152417  1.2325557571  0.987104356 -0.1280708587
 [16,] -0.67670149 -0.5137386673 -0.225271771 -0.2467856186
 [17,] -0.38818343  0.9315373449  0.016684915  0.0188255725
 [18,]  1.16932824 -0.2741924354 -1.059346761 -0.1435005894
 [19,] -0.66153125  0.2122802593 -0.223007736  0.4313433164
 [20,]  1.08242816 -1.9334151885 -0.960408756 -0.7294112470
 [21,]  0.88031155  0.4650943496  0.774347635 -0.1043154767
 [22,] -0.42529351  0.3147396632 -0.265845908 -0.6854368687
 [23,] -1.48420700 -0.8374164318  0.344388290 -0.0832479092
 [24,] -0.21453611 -0.3113184077  0.131932038  0.7109508781
 [25,]  0.13172715 -0.3859604302  0.550866016  0.0832605151
 [26,]  0.84418334  0.3737964245  0.302790892 -0.6373902045
 [27,]  0.64894344  0.0263196119 -0.204386762  0.1977920874
 [28,] -0.57769627 -0.2107436724  0.842494773  0.6107789562
 [29,]  0.03847653 -0.3481976965  0.158923847 -0.3400519529
 [30,] -0.36799890  0.6844245527  0.278998115  0.1093186813
 [31,] -0.61964373  0.1621316116 -0.024690176 -0.0284536389
 [32,]  1.14464537  1.1809030754 -0.380505425  0.3701559647
 [33,] -0.14812084  0.2584569079  0.729240462 -0.1457276845
 [34,] -0.38505750  0.7496313047  1.223032412  0.1940544823
 [35,]  1.20300498 -0.4184135274  0.102978550  0.2436012027
 [36,] -0.11572761  0.6931371269 -0.730358909  0.0919469088
 [37,]  0.60036267  0.0552615456 -0.504122435  0.0743124065
 [38,]  0.36552343 -0.6133204083 -0.221451464 -0.2428960478
 [39,] -1.17948407 -0.1979367583  0.443798898  0.0343502452
 [40,] -0.37153649  1.3696763862 -0.201736227  0.2290697334
 [41,]  0.64702070 -0.8626641199 -0.136466380  0.0903686007
 [42,]  0.55584268 -1.5618624118 -0.156663397  0.2879771229
 [43,] -1.15342324  0.2858810684 -0.971969885 -0.1206248038
 [44,]  0.46837955 -0.2933837423  0.006414474  0.0948067899
 [45,]  0.05655208 -0.5357052764  0.062286515  0.1228486772
 [46,] -0.72316351  0.3385209810  0.275512280  0.2943953455
 [47,]  0.10025293  0.4666816487 -0.786995490  0.1705890199
 [48,] -0.92818008 -0.0613057859  0.031530233 -0.1004930647
 [49,] -0.21407675 -1.4921691915 -0.144735124 -0.1910429600
 [50,]  0.12529223 -0.6281021405  0.001047391 -0.0490617584
 [51,] -0.29040102  1.2344298307 -0.291856876  0.1419083685
 [52,] -0.41210327  0.3230682314 -0.002398173  0.2736864222
 [53,]  0.01268325  0.4610478069 -0.460363755 -0.0267408764
 [54,] -0.57929826 -0.2408257732 -0.860195018 -0.3504698437
 [55,]  1.18615233  0.4751033403 -0.427729795 -0.4353113862
 [56,]  0.42397854 -0.4941546251 -0.170503396  0.2574069467
 [57,] -0.43709805 -1.0326097580  0.672174563  0.0708619725
 [58,] -0.01223762 -0.7616156308  0.106056018 -0.1011161223
 [59,]  1.78578300 -0.9849418558  0.352315636  0.3457747483
 [60,]  0.79718264  1.1746713142  0.475867946 -0.2161104264
 [61,]  0.89502134 -1.1676065123 -0.332601746  0.3598091138
 [62,]  1.30443242 -0.9180805128 -0.195046413  0.3470582351
 [63,]  1.88586618 -0.1944611969 -0.026732491 -0.0877703610
 [64,] -0.44711097 -0.3589136623 -0.222777067  0.2145727056
 [65,] -1.78691859  0.0366590204 -0.880531123  0.1446067634
 [66,]  1.08346231  0.1904351142  0.423005815  0.5721919645
 [67,] -0.13243389 -0.0041027920 -0.687289154  0.3023959134
 [68,] -0.18660093  1.1775829349 -0.413634410  0.0303394867
 [69,] -0.17569966  0.0573560197 -0.620558652 -0.0155053350
 [70,]  0.05624385  0.3600318193 -0.514779041  0.0661945732
 [71,] -1.04595389 -0.7242703963 -0.177232321 -0.7429703035
 [72,]  0.74474813 -0.6618760140  0.596390293 -0.3154192518
 [73,] -0.40726490  0.1502844086 -0.259366309  0.0346973275
 [74,] -0.25102010  0.2840362338 -0.080935740  0.0625714810
 [75,] -0.08516767  0.5316145010  0.383194265  0.2787410615
 [76,]  1.17470811  0.5679497150 -0.498805006  0.1970398605
 [77,]  0.22487897 -0.2220594993 -0.469726165 -0.0337793091
 [78,] -1.34950551 -0.1729952279  0.272591541 -0.0193634169
 [79,]  0.25186962 -0.0841761588 -0.374118151  0.1346817963
 [80,] -0.05037133  0.4637262327  0.436147462 -0.2186125660
 [81,] -0.66822754 -0.6373527018  0.110021565 -0.2293764317
 [82,]  0.55042571  1.3885696455 -0.614670777 -0.2219156654
 [83,] -0.11123472 -0.2126298539  0.591466438 -0.1201875076
 [84,]  0.74654727 -1.2068097696 -0.075756196 -0.1185488824
 [85,] -0.05741597 -0.6960969127  0.217700467 -0.3229946973
 [86,] -1.09451079  0.8341393993  0.536873392 -1.0771083927
 [87,] -1.63731887 -0.4500412022  0.156222203 -0.2084373784
 [88,] -0.38473909  0.1863293169  0.627674871  0.0019942063
 [89,] -0.84923348  0.9852565983  0.096704306 -0.1403820376
 [90,]  1.08721164 -1.2595408390 -0.505560488  0.1147898464
 [91,] -0.79426042  0.5691848270  0.314076894  0.2162917288
 [92,] -0.29749775 -0.6942201564  0.251153014  0.4071688479
 [93,] -0.13009851 -0.6448082544 -0.215171550 -0.0013707030
 [94,]  0.16419637  0.6636855819  0.117917574  0.2582072942
 [95,] -0.35715787  0.0157901025 -0.875395280 -0.0252499649
 [96,]  0.65730102 -1.0818509291 -0.232869385  0.3136940915
 [97,]  1.76128665  1.2657590588  0.439137181  0.4649356903
 [98,]  0.09250760  0.2757859167 -0.236257718  0.1052027223
 [99,]  0.14259294 -0.5807299626 -0.138778976 -0.2634627765
[100,] -0.95034889 -1.3372587751  0.406069290  0.0180576535
[101,]  0.87817071 -0.4087743197  0.226127279 -0.0414162404
[102,] -0.61947860 -0.2505638062 -0.675498028  0.1356607953
[103,] -0.46642078  0.0290852684  0.401003026  0.0255724458
[104,]  0.14468330 -0.6739671163  1.225772029 -0.0276230569
[105,] -1.13022539  0.2773781416 -0.476423301  0.0437997012
[106,]  1.18894239 -0.4359736884  0.689497965 -0.0453164589
[107,] -0.81340422  1.6439255369 -0.536768283 -0.0754513858
[108,]  0.15609962 -0.0722779271  0.502810206 -0.3398499147
[109,]  0.08350754  1.2282958401 -0.223957673 -0.0169307437
[110,]  0.75561167  1.0438868457  0.116573141  0.0935973098
[111,]  0.25871682  0.8823792164 -0.171864861  0.1428006252
[112,]  0.12657523  0.6642642613 -0.702139641  0.0996956684
[113,]  0.29034362 -0.2995001519 -0.172938592  0.0683426928
[114,] -0.30883888 -0.0872639086 -0.444025251  0.4492350806
[115,] -0.06272391  0.1488930877  0.396482900  0.3927152314
[116,] -1.07803338 -0.5974545662 -0.140624656 -0.1575316545
[117,] -0.27523119  0.3741957465  1.135471996 -0.3695996503
[118,]  0.60108345  1.0834727575 -0.750337794 -0.4682216666
[119,] -0.24820695 -0.6302235835  0.293085733 -0.0946537230
[120,] -0.39300958  0.8209531382 -0.105888730  0.4416476082
[121,] -1.05421659 -0.7931740440  0.491234172 -0.0543568979
[122,] -0.52044693  0.3735806370  0.124783178 -0.0918212849
[123,] -0.15837686  0.6569802777  0.321399041 -0.0551519369
[124,] -0.66071857  0.2863046425  0.750688554  0.0977300156
[125,] -0.88457263  0.0501600498  0.002523285  0.0936804606
[126,]  0.53304908  0.2260481971 -0.421859089 -0.1153969233
[127,]  1.07232078  0.5243568166 -0.047318620 -0.0274594865
[128,]  0.37025629  0.4389319782  0.140848962  0.0402303752
[129,] -0.33791822  0.2064795848  0.322490623 -0.0947682864
[130,]  0.90513614 -0.4304847412 -0.483666609 -0.4455543554
[131,]  1.48904320 -0.5118009377  1.043228428 -0.6282342192
[132,] -0.09259844 -0.1219959640 -0.195516631 -0.2868958730
[133,] -0.16494305 -0.5939604564  0.902530629  0.4136181503
[134,] -2.07502630  0.8229031840 -1.312599279 -0.1616872750
[135,] -0.67960566  0.1075664785  0.291926635  0.3337062766
[136,] -0.12020068 -0.8428504058 -0.532955595  0.0512696380
[137,] -0.81847484 -0.6865965856 -1.028128947 -0.0009624595
[138,] -0.25601418 -0.5807503264 -0.709502550 -0.3378587098
[139,] -1.26621978  0.3838941846  0.549320520 -0.9831792326
[140,]  0.40841904  0.0258347804  0.439800500 -0.1322951404
[141,]  0.13435070  0.0659528009  0.482764628 -0.3297422797
[142,]  0.95581155  0.7097465046 -0.228212611 -0.1429372260
[143,] -0.46029245  0.3183868941 -0.587042794 -0.1197356711
[144,] -0.67307755  0.1889939725  0.422625053 -0.0399881740
[145,] -0.60724230 -1.2748664214  0.411839179  0.0920733012
[146,]  0.17781446  1.2525109457 -1.184768000 -0.0562904408
[147,]  0.11633907 -0.6212582279 -0.436419460  0.0339510324
[148,] -0.05351440 -0.2052347425  0.680763865  0.1460563854
[149,]  0.16421475  0.3107183613 -0.659322126  0.1206929279
[150,]  0.71546745  0.0300289246  0.374038794 -0.0654860699
[151,]  0.15452584 -0.0570135573  0.328205155 -0.0170010789
[152,]  0.60771963 -0.7077763541  0.104418749 -0.5978677866
[153,]  0.44893088 -0.1030706219  0.189253883 -0.2294621575
[154,]  0.09908638  0.3794549680  0.206645730  0.2200877886
[155,]  0.07625279  0.4789181516  0.169424540  0.4052499230
[156,]  0.50749068  0.4671282535 -1.357495497  0.1927496678
[157,] -0.38813250  0.8750910745  0.357016737  0.1282757241
[158,]  0.66777666 -0.2895885882  0.311322830  0.2271212691
[159,]  0.47622122  0.0701984051  0.008518705  0.3687591382
[160,] -0.30730932 -1.7100957993 -1.257522926  0.0721893875
[161,] -0.55935977 -0.2218714286 -0.133109186  0.1743894719
[162,] -0.98648339 -0.0024557258  0.874305148  0.0096693542
[163,]  0.18385252  1.4193818419  1.055869546  0.1568441386
[164,]  0.41644698 -0.0524082513 -0.072759229 -0.0517202212
[165,]  0.15812615 -0.4391852307  0.194231409  0.0682007662
[166,] -0.04045587 -0.1786382316  0.526897230  0.0810134306
[167,] -0.05582319  0.3711379285  0.472271094  0.2636395514
[168,]  0.52149401  0.0420751357  0.670175919 -0.0874117462
[169,] -0.43693685  0.5154044366  0.419625332  0.3484137352
[170,] -0.70506025 -0.5076188489 -0.052354506 -0.2630716849
[171,] -0.81775468  0.3000833952 -0.354779368  0.0293493079
[172,] -0.33899623  0.6757625185  0.128643570 -0.0741570841
[173,]  0.02718865 -0.3847806190 -0.472207472 -0.4002744925
[174,] -0.06496227 -0.2137438037  0.162986721  0.0095219744
[175,]  0.07579987 -0.3430895763  0.391920290  0.5485428831
[176,] -0.56163716 -0.3982926335  0.237344530 -0.7613848634
[177,] -0.04360380 -0.1596709040 -0.288610265  0.0834730615
[178,] -0.51012016  0.0003966639  0.262671482 -0.0459775518
[179,] -1.67166063  1.3488880331 -0.145116511  0.1191770845
[180,]  0.53521583 -0.0140391472 -0.829014956 -0.3304228288
[181,] -0.79827790 -1.1265757773 -0.235752910 -0.0038937033
[182,]  0.06770910 -0.3904053103 -0.001014213  0.0393503121
[183,]  0.85056939 -0.4793463610 -0.633619617  0.0735806454
[184,] -0.47523820 -0.0475453513 -0.255408472  0.1470210371
[185,] -0.21831151 -0.4003557013  0.419609656 -0.2915971914
[186,] -0.22539323 -1.3346371861  0.123219610 -0.0104449998
[187,]  0.30367518  0.3479009409  0.653404119  0.2586098127
[188,] -1.31138705  0.4655335941  0.315324610  0.2581708162
[189,]  0.25146744  0.0422435931  0.700907436  0.5205045386
[190,]  0.38028985  1.9057762639 -0.538512501  0.0010733648
[191,]  0.31418320 -0.4886161020  0.119593068 -0.5128790374
[192,]  0.63503748  1.3835392863  1.127970995 -0.8432248449
[193,] -0.10874341  0.2643755985  0.288762029  0.0471833528
[194,]  0.88657738 -0.3576209130  0.366290110  0.0438075171
[195,]  0.72776671 -1.9228421047 -1.445715934  0.2233912419
[196,] -0.94137355  0.7757570226  0.045238047 -0.4250260915
[197,] -1.91858924 -0.0488341490 -0.052590288 -0.6225575533
[198,] -0.37380028  0.9455242694  0.871930604 -0.5328960237
[199,] -0.24764564 -0.1928071465  0.641110498  0.1554724410
[200,] -1.24014451  1.4231338609 -0.450424445 -0.2977577042
[201,] -0.44718016 -0.2138133798 -0.200592118  0.2412184164
[202,] -0.79758401 -0.5794486527 -0.107607139 -0.1219273363
[203,]  0.41602473  0.2846160031 -0.035409926  0.1519609694
[204,]  0.28790269  1.1827764506  0.743804100 -0.2375070734
[205,] -0.44991631 -0.4658826497 -0.353334875  0.1614580210
[206,]  0.05724589 -0.4384146051 -0.710078381 -0.3204541095
[207,] -1.21184344  2.2270403916 -1.510256241 -0.9775440573
[208,] -0.13345067 -0.3709585115  0.046348331 -0.0048341049
[209,]  0.61489357 -0.6676808739  0.526792600 -0.1551294270
[210,]  0.73344416 -0.3178335014  0.567983635  0.3406914976
[211,]  1.23386941  0.4027317370 -0.118000072  0.3570094448
[212,] -0.38001560  1.2911310207 -0.104152200 -0.3807265041
[213,] -5.58327821 -0.8078813340 -1.184578405  2.9494261303
[214,] -1.59859206  0.3657226626  1.210010697 -0.3095491397
[215,]  0.48769192 -0.6990111164 -0.076604693  0.0953780509
[216,] -0.25983567  1.3935842073 -0.644830413  0.0760409341
[217,] -1.15725248 -0.4777955838  1.627914509 -0.1681201834
[218,]  0.76831900 -1.3726642023  0.138304377 -0.5277051948
[219,]  0.21576616  1.3111818792  0.152262032 -0.0229367486
[220,]  0.13015108 -0.0746222186  0.049399436  0.0083598396
[221,]  0.15341863 -0.2980677293 -1.005336913 -0.0867832197
[222,]  0.69670877 -0.5579544222 -0.371459236  0.2268811720
[223,]  0.13815316 -0.0418408114 -0.343354673 -0.8148326202
[224,] -1.14035236  0.0836348997  0.038160033  0.3013850917
[225,]  1.08442224  0.1888930905  0.248745744  0.1407296220
[226,] -0.89338394 -0.3491716065 -0.745643362 -0.1096266459
[227,] -0.85390102 -0.6588038790 -0.082281815 -0.1773419432
[228,] -0.10964290  0.4794590590 -0.097340402  0.1554362045
[229,]  0.21916124 -0.8951842978 -0.947463819 -0.0965853300
[230,] -1.85507162 -0.1049073123 -1.010859335 -0.3648449270
[231,]  0.82495869 -0.2376114588  0.323672666 -0.2072439815
[232,]  0.35830790  1.0316879970  0.205733105  0.1947397740
[233,] -1.10349804  0.1267281297  0.581897796 -0.2431708223
[234,] -0.50194981  0.6248778034 -1.128794257 -0.4326963310
[235,]  0.19963892  0.2852475490 -0.018107243 -0.0956813890
[236,] -0.92280204  0.3596850715  0.700851638 -0.1181486554
[237,]  0.10089656  0.6429615676 -0.914613335 -0.1310744373
[238,]  0.76603503  0.5346742758  0.250230166  0.1361993561
[239,]  0.77191503  0.9628338332 -0.462106741  0.1630092292
[240,]  1.82334872  0.3857172072  0.646260975  0.0952865103
[241,] -0.14914909  0.1658468047 -0.448673879  0.1520755102
[242,]  0.34935425 -0.3172289977  0.064423109  0.3410570145
[243,]  0.92948138  0.7374355648  0.188752899 -0.2253918212
[244,]  0.09805683  0.9186485244  0.390657914  0.5025300740
[245,] -0.06067322  0.2196684557  0.484987741  0.1430187799
[246,] -0.20902609  0.4203399964  0.905010462 -0.1591260255
[247,]  0.99070339 -0.4397014033 -0.925669802 -1.0224937104
[248,]  0.34366472  0.4862695256 -0.619254887 -0.1300602740
[249,]  0.91066245 -0.5864986218 -0.137402258  0.1909704585
[250,]  0.52728220 -1.3984620896  0.910203238  0.1571887950
[251,] -0.68509850 -2.2264025982 -0.763899005 -0.0768239030
[252,]  0.45877624 -0.8193490534 -0.579284863 -0.4972768144
[253,] -1.02277884  0.1193051054  0.620359773 -0.5599105213
[254,]  0.36765388  0.1966668866 -0.644922137 -0.1852289035
[255,] -2.33694560 -1.2379793560 -0.508898189 -1.7588965443
[256,]  0.91264792  1.1258451678 -0.369836457  0.2572322873
[257,] -0.57880284 -0.1264246166  0.908236779 -0.2174853161
[258,]  0.33989856 -0.1576345066  0.656172504  0.2332684374
[259,] -0.21467671  0.8923462161  0.720945118 -0.1444405819
[260,] -1.20238876 -0.4519462656  0.022868017  0.2196719345
[261,]  0.18753195  0.5535933787 -0.132384934  0.3876970368
[262,]  1.03407762  0.1385414588 -0.274429826 -0.1588819722
[263,]  1.81264364  0.5406512886  0.593791785  0.1018653939
[264,] -0.31421382 -0.0337847178 -0.420899586  0.0391403271
[265,]  0.72255949 -0.1995553328  0.410041593  0.1171581847
[266,] -0.34223135  0.1205076640 -0.470600949 -0.1858786223
[267,] -0.07470815 -0.2561653528 -0.694886997  0.3641145993
[268,]  0.10783829 -0.5097127118 -0.188655907  0.0690412875
[269,]  0.32042077 -0.2193836079 -0.189532358 -0.0764980625
[270,]  1.23906900  0.0669024853  0.338758630 -0.1160748156
[271,]  0.08300095 -1.6573476776  0.055542492 -0.1849954464
[272,]  1.34640007 -0.5433164013  0.592852975  0.3566928964
[273,]  0.50416539 -1.4712518397  0.551814998  0.1688386075
[274,] -0.04825834 -0.0540114970  0.413122383  0.1299717859
[275,] -0.46351400  0.1610118509 -0.124125433 -0.1484456591
[276,]  0.41746863 -0.7099263938  0.039750760 -0.3059740818
[277,]  0.60596766  0.6012509769 -0.596033241  0.0254770084
[278,]  0.52078378  0.7660413424 -1.557720772 -0.2869550113
[279,]  0.04386567  0.8952448942 -0.035826538  0.0638347823
[280,] -0.62246393 -0.2789671579  0.132589730  0.0043822104
[281,] -0.34397297  0.1733680637 -0.295654179  0.0497671949
[282,]  0.11149413 -0.3067336422 -0.421250922 -0.2523380202
[283,] -0.38152042 -0.2118324006  0.217888315 -0.0297526812
[284,] -0.22394214 -1.1988041169  0.339441379 -0.2671376149
[285,]  0.89436129 -0.2202340371 -0.335950603  0.1816913161
[286,]  0.74752767 -0.6323140068 -0.195514992  0.4745065107
[287,]  0.90554015 -0.5765639894  0.304528337 -0.6068117413
[288,]  1.65077907  0.0294455191  0.996376439  0.6030226922
[289,]  0.20870801  0.0571565219 -0.604329343  0.1767243064
[290,] -1.61106274 -1.0156687810  2.968071574 -0.1365328117
[291,]  0.39771717  0.6243184560  0.328294655  0.3406465046
[292,] -0.63840615  0.9777383766 -0.035197616  0.0769228420
[293,] -0.15358695 -1.2065472084  0.105256515  0.0803347313
[294,]  1.34825912  0.2954142880 -0.365378723  0.5183646171
[295,]  1.00889596  1.0591567970 -0.999530368  0.4381810780
[296,]  0.45818926 -0.4333327755  0.455146961  0.3952242090
[297,]  0.65569141  0.5397752855 -0.184456664  0.2318170108
[298,]  0.62478954  0.5846643131 -0.279716382  0.3574752234
[299,] -0.03751692  0.2736321737  0.320659656  0.2144822300
[300,]  0.04815721 -0.1044056678  0.101203735 -0.2092842205
[301,]  0.38542812 -0.8687649905 -0.016430687 -0.1929220110
[302,]  0.90774061 -0.0441999422  0.639993953  0.3016422400
[303,]  0.06173965  0.6262764607 -0.220377323  0.0493965885
[304,] -0.57682966 -0.0529164172 -0.877677661 -0.2153749933
[305,] -0.33037268 -1.0379666040  0.047040470 -0.0305480148
[306,]  0.81562183 -0.1357050853 -0.067520331  0.1546680098
[307,]  0.86731898  0.1381674770 -0.671642517  0.3694016590
[308,]  0.26889600 -1.0684829133 -0.498763645 -0.0370602803
[309,]  0.07792106 -0.8867133829 -0.404632462  0.1267726601
[310,] -0.63086736  0.2085258640  0.115525492  0.1469036256
[311,]  0.39675779 -0.2220016244  0.048408771  0.0690490126
[312,] -0.61549286  0.3320391606 -0.180546906  0.0054449867
[313,] -0.11911021  0.2989890979  0.203596960  0.1520547265
[314,] -0.41407743 -1.4208787266  0.201397434  0.7478453094
[315,] -0.16147414  0.0570180035  0.591750402 -0.3171120941
[316,] -0.70224081  0.8031892835  0.702164834  0.2232106391
[317,] -0.80781957  0.4284071971  0.559279716 -0.0308750605
[318,]  1.54203926  1.1457529897  0.694663256  0.5013517307
[319,]  0.02411639  0.7598343213 -0.434866031  0.0540074461
[320,]  0.28995160  0.1606643195  0.113117817  0.2734342366
[321,] -0.20510588  0.0034887195 -0.051368865  0.0262538576
[322,]  0.01767954  0.0795690009  0.429743883 -0.0649673806
[323,]  0.60203587  0.2404754512 -0.309126556  0.0950808419
[324,]  0.27232587  1.4225185576  0.221996369 -0.3365644435
[325,]  0.34811386  0.1590543834  0.309007802 -0.4005043131
[326,]  0.02781104  0.2578027139 -0.062501862  0.1448350292
[327,] -0.34488256  0.1708766916  0.136739228  0.1658618810
[328,]  0.02706346  0.4031505640  0.390746647  0.0576405432
[329,] -0.30628652 -0.5861626977  0.571340630  0.0878835920
#adding PC1 and PC2 to the places data set 
places <- places %>%
  mutate(
    PC1 = places_pca$x[, 1],
    PC2 = places_pca$x[, 2]
  )


#graphing the biplot of the first 2 PCs
library(ggplot2)
library(ggrepel)


#Putting the place values into the scores   
scores <- as.data.frame(places_pca$x[, 1:2])
scores$City <- places$City


loadings <- as.data.frame(places_pca$rotation[, 1:2])
loadings$Variable <- rownames(loadings)

 
ggplot(scores, aes(PC1, PC2, label = City)) +
  geom_point(color = "blue") +
  geom_text_repel(size = 3) +
  geom_segment(data = loadings,
               inherit.aes = FALSE, 
               aes(x = 0, y = 0,
                   xend = PC1 * 3,
                   yend = PC2 * 3),
               arrow = arrow(length = unit(0.2, "cm")),
               color = "red") +
  geom_text_repel(data = loadings,
                  inherit.aes = FALSE,
                  aes(x = PC1 * 3, y = PC2 * 3, label = Variable),
                  color = "red") +
  theme_minimal() +
  labs(title = "Biplot of First Two Principal Components")
Warning: ggrepel: 305 unlabeled data points (too many overlaps). Consider
increasing max.overlaps

#some pretty obvious outliers are NYC (New York City), Chicago IL,
#San Francisco CA, Washington DC, Boston MA, Los Angeles CA, Philadelphia PA generally the largest metropolitans would be
#the outliers I spotted. The specific metrics that make them the 
#largest outliers are the arts, health care and education for 
#cities like NYC, Boston & Chicago. While metrics like Housing &
#Recreat make cities like Los Angeles CA and San Francisco CA #biggest outliers. 

Problem 4

The data we will look at here come from a study of malignant and benign breast cancer cells using fine needle aspiration conducted at the University of Wisconsin-Madison. The goal was determine if malignancy of a tumor could be established by using shape characteristics of cells obtained via fine needle aspiration (FNA) and digitized scanning of the cells.

The variables in the data file you will be using are:

  • ID - patient identification number (not used in PCA)
  • Diagnosis determined by biopsy - B = benign or M = malignant
  • Radius: mean of distances from center to points on the perimeter
  • Texture: standard deviation of gray-scale values
  • Smoothness: local variation in radius lengths
  • Compactness: perimeter^2 / area - 1.0
  • Concavity: severity of concave portions of the contour
  • Concavepts: number of concave portions of the contour
  • Symmetry: measure of symmetry of the cell nucleus
  • FracDim: fractal dimension; “coastline approximation” - 1
#reading in the dataset
bc_cells <- read.csv("C:/Users/lr7273ow/OneDrive - Minnesota State/Documents/GitHub/DSCI_415/Activities/Data/BreastDiag.csv")
head(bc_cells)
  Diagnosis Radius Texture Smoothness Compactness Concavity ConcavePts Symmetry
1         M  17.99   10.38    0.11840     0.27760    0.3001    0.14710   0.2419
2         M  20.57   17.77    0.08474     0.07864    0.0869    0.07017   0.1812
3         M  19.69   21.25    0.10960     0.15990    0.1974    0.12790   0.2069
4         M  11.42   20.38    0.14250     0.28390    0.2414    0.10520   0.2597
5         M  20.29   14.34    0.10030     0.13280    0.1980    0.10430   0.1809
6         M  12.45   15.70    0.12780     0.17000    0.1578    0.08089   0.2087
  FracDim
1 0.07871
2 0.05667
3 0.05999
4 0.09744
5 0.05883
6 0.07613
bc_cells_cols <- bc_cells  %>% 
  select('Radius','Texture','Smoothness','Compactness','Concavity','ConcavePts','Symmetry','FracDim')

bc_cells_cols
    Radius Texture Smoothness Compactness Concavity ConcavePts Symmetry FracDim
1   17.990   10.38    0.11840     0.27760 0.3001000   0.147100   0.2419 0.07871
2   20.570   17.77    0.08474     0.07864 0.0869000   0.070170   0.1812 0.05667
3   19.690   21.25    0.10960     0.15990 0.1974000   0.127900   0.2069 0.05999
4   11.420   20.38    0.14250     0.28390 0.2414000   0.105200   0.2597 0.09744
5   20.290   14.34    0.10030     0.13280 0.1980000   0.104300   0.1809 0.05883
6   12.450   15.70    0.12780     0.17000 0.1578000   0.080890   0.2087 0.07613
7   18.250   19.98    0.09463     0.10900 0.1127000   0.074000   0.1794 0.05742
8   13.710   20.83    0.11890     0.16450 0.0936600   0.059850   0.2196 0.07451
9   13.000   21.82    0.12730     0.19320 0.1859000   0.093530   0.2350 0.07389
10  12.460   24.04    0.11860     0.23960 0.2273000   0.085430   0.2030 0.08243
11  16.020   23.24    0.08206     0.06669 0.0329900   0.033230   0.1528 0.05697
12  15.780   17.89    0.09710     0.12920 0.0995400   0.066060   0.1842 0.06082
13  19.170   24.80    0.09740     0.24580 0.2065000   0.111800   0.2397 0.07800
14  15.850   23.95    0.08401     0.10020 0.0993800   0.053640   0.1847 0.05338
15  13.730   22.61    0.11310     0.22930 0.2128000   0.080250   0.2069 0.07682
16  14.540   27.54    0.11390     0.15950 0.1639000   0.073640   0.2303 0.07077
17  14.680   20.13    0.09867     0.07200 0.0739500   0.052590   0.1586 0.05922
18  16.130   20.68    0.11700     0.20220 0.1722000   0.102800   0.2164 0.07356
19  19.810   22.15    0.09831     0.10270 0.1479000   0.094980   0.1582 0.05395
20  13.540   14.36    0.09779     0.08129 0.0666400   0.047810   0.1885 0.05766
21  13.080   15.71    0.10750     0.12700 0.0456800   0.031100   0.1967 0.06811
22   9.504   12.44    0.10240     0.06492 0.0295600   0.020760   0.1815 0.06905
23  15.340   14.26    0.10730     0.21350 0.2077000   0.097560   0.2521 0.07032
24  21.160   23.04    0.09428     0.10220 0.1097000   0.086320   0.1769 0.05278
25  16.650   21.38    0.11210     0.14570 0.1525000   0.091700   0.1995 0.06330
26  17.140   16.40    0.11860     0.22760 0.2229000   0.140100   0.3040 0.07413
27  14.580   21.53    0.10540     0.18680 0.1425000   0.087830   0.2252 0.06924
28  18.610   20.25    0.09440     0.10660 0.1490000   0.077310   0.1697 0.05699
29  15.300   25.27    0.10820     0.16970 0.1683000   0.087510   0.1926 0.06540
30  17.570   15.05    0.09847     0.11570 0.0987500   0.079530   0.1739 0.06149
31  18.630   25.11    0.10640     0.18870 0.2319000   0.124400   0.2183 0.06197
32  11.840   18.70    0.11090     0.15160 0.1218000   0.051820   0.2301 0.07799
33  17.020   23.98    0.11970     0.14960 0.2417000   0.120300   0.2248 0.06382
34  19.270   26.47    0.09401     0.17190 0.1657000   0.075930   0.1853 0.06261
35  16.130   17.88    0.10400     0.15590 0.1354000   0.077520   0.1998 0.06515
36  16.740   21.59    0.09610     0.13360 0.1348000   0.060180   0.1896 0.05656
37  14.250   21.72    0.09823     0.10980 0.1319000   0.055980   0.1885 0.06125
38  13.030   18.42    0.08983     0.03766 0.0256200   0.029230   0.1467 0.05863
39  14.990   25.20    0.09387     0.05131 0.0239800   0.028990   0.1565 0.05504
40  13.480   20.82    0.10160     0.12550 0.1063000   0.054390   0.1720 0.06419
41  13.440   21.58    0.08162     0.06031 0.0311000   0.020310   0.1784 0.05587
42  10.950   21.35    0.12270     0.12180 0.1044000   0.056690   0.1895 0.06870
43  19.070   24.81    0.09081     0.21900 0.2107000   0.099610   0.2310 0.06343
44  13.280   20.28    0.10410     0.14360 0.0984700   0.061580   0.1974 0.06782
45  13.170   21.81    0.09714     0.10470 0.0825900   0.052520   0.1746 0.06177
46  18.650   17.60    0.10990     0.16860 0.1974000   0.100900   0.1907 0.06049
47   8.196   16.84    0.08600     0.05943 0.0158800   0.005917   0.1769 0.06503
48  13.170   18.66    0.11580     0.12310 0.1226000   0.073400   0.2128 0.06777
49  12.050   14.63    0.10310     0.09092 0.0659200   0.027490   0.1675 0.06043
50  13.490   22.30    0.08752     0.07698 0.0475100   0.033840   0.1809 0.05718
51  11.760   21.60    0.08637     0.04966 0.0165700   0.011150   0.1495 0.05888
52  13.640   16.34    0.07685     0.06059 0.0185700   0.017230   0.1353 0.05953
53  11.940   18.24    0.08261     0.04751 0.0197200   0.013490   0.1868 0.06110
54  18.220   18.70    0.11480     0.14850 0.1772000   0.106000   0.2092 0.06310
55  15.100   22.02    0.09056     0.07081 0.0525300   0.033340   0.1616 0.05684
56  11.520   18.75    0.09524     0.05473 0.0303600   0.022780   0.1920 0.05907
57  19.210   18.57    0.10530     0.12670 0.1323000   0.089940   0.1917 0.05961
58  14.710   21.59    0.11370     0.13650 0.1293000   0.081230   0.2027 0.06758
59  13.050   19.31    0.08060     0.03789 0.0006920   0.004167   0.1819 0.05501
60   8.618   11.79    0.09752     0.05272 0.0206100   0.007799   0.1683 0.07187
61  10.170   14.88    0.11340     0.08061 0.0108400   0.012900   0.2743 0.06960
62   8.598   20.98    0.12430     0.08963 0.0300000   0.009259   0.1828 0.06757
63  14.250   22.15    0.10490     0.20080 0.2135000   0.086530   0.1949 0.07292
64   9.173   13.86    0.07721     0.08751 0.0598800   0.021800   0.2341 0.06963
65  12.680   23.84    0.11220     0.12620 0.1128000   0.068730   0.1905 0.06590
66  14.780   23.94    0.11720     0.14790 0.1267000   0.090290   0.1953 0.06654
67   9.465   21.01    0.10440     0.07773 0.0217200   0.015040   0.1717 0.06899
68  11.310   19.04    0.08139     0.04701 0.0370900   0.022300   0.1516 0.05667
69   9.029   17.33    0.10660     0.14130 0.3130000   0.043750   0.2111 0.08046
70  12.780   16.49    0.09831     0.05234 0.0365300   0.028640   0.1590 0.05653
71  18.940   21.31    0.09009     0.10290 0.1080000   0.079510   0.1582 0.05461
72   8.888   14.64    0.09783     0.15310 0.0860600   0.028720   0.1902 0.08980
73  17.200   24.52    0.10710     0.18300 0.1692000   0.079440   0.1927 0.06487
74  13.800   15.79    0.10070     0.12800 0.0778900   0.050690   0.1662 0.06566
75  12.310   16.52    0.09172     0.06829 0.0337200   0.022720   0.1720 0.05914
76  16.070   19.65    0.09168     0.08424 0.0976900   0.066380   0.1798 0.05391
77  13.530   10.94    0.12910     0.10470 0.0687700   0.065560   0.2403 0.06641
78  18.050   16.15    0.10650     0.21460 0.1684000   0.108000   0.2152 0.06673
79  20.180   23.97    0.12860     0.34540 0.3754000   0.160400   0.2906 0.08142
80  12.860   18.00    0.09934     0.09546 0.0388900   0.023150   0.1718 0.05997
81  11.450   20.97    0.11020     0.09362 0.0459100   0.022330   0.1842 0.07005
82  13.340   15.86    0.10780     0.15350 0.1169000   0.069870   0.1942 0.06902
83  25.220   24.91    0.10630     0.26650 0.3339000   0.184500   0.1829 0.06782
84  19.100   26.29    0.12150     0.17910 0.1937000   0.146900   0.1634 0.07224
85  12.000   15.65    0.09723     0.07165 0.0415100   0.018630   0.2079 0.05968
86  18.460   18.52    0.09874     0.10530 0.1335000   0.087950   0.2132 0.06022
87  14.480   21.46    0.09444     0.09947 0.1204000   0.049380   0.2075 0.05636
88  19.020   24.59    0.09029     0.12060 0.1468000   0.082710   0.1953 0.05629
89  12.360   21.80    0.08772     0.09445 0.0601500   0.037450   0.1930 0.06404
90  14.640   15.24    0.11320     0.13390 0.0996600   0.070640   0.2116 0.06346
91  14.620   24.02    0.08974     0.08606 0.0310200   0.029570   0.1685 0.05866
92  15.370   22.76    0.09200     0.10360 0.1122000   0.074830   0.1717 0.06097
93  13.270   14.76    0.07355     0.05055 0.0326100   0.026480   0.1386 0.05318
94  13.450   18.30    0.10220     0.08165 0.0397400   0.027800   0.1638 0.05710
95  15.060   19.83    0.10390     0.15530 0.1700000   0.088150   0.1855 0.06284
96  20.260   23.03    0.09078     0.13130 0.1465000   0.086830   0.2095 0.05649
97  12.180   17.84    0.10450     0.07057 0.0249000   0.029410   0.1900 0.06635
98   9.787   19.94    0.10240     0.05301 0.0068290   0.007937   0.1350 0.06890
99  11.600   12.84    0.08983     0.07525 0.0419600   0.033500   0.1620 0.06582
100 14.420   19.77    0.09752     0.11410 0.0938800   0.058390   0.1879 0.06390
101 13.610   24.98    0.09488     0.08511 0.0862500   0.044890   0.1609 0.05871
102  6.981   13.43    0.11700     0.07568 0.0000000   0.000000   0.1930 0.07818
103 12.180   20.52    0.08013     0.04038 0.0238300   0.017700   0.1739 0.05677
104  9.876   19.40    0.10050     0.09697 0.0615400   0.030290   0.1945 0.06322
105 10.490   19.29    0.09989     0.08578 0.0299500   0.012010   0.2217 0.06481
106 13.110   15.56    0.13980     0.17650 0.2071000   0.096010   0.1925 0.07692
107 11.640   18.33    0.11420     0.10170 0.0707000   0.034850   0.1801 0.06520
108 12.360   18.54    0.08477     0.06815 0.0264300   0.019210   0.1602 0.06066
109 22.270   19.67    0.13260     0.27680 0.4264000   0.182300   0.2556 0.07039
110 11.340   21.26    0.08759     0.06575 0.0513300   0.018990   0.1487 0.06529
111  9.777   16.99    0.10370     0.08404 0.0433400   0.017780   0.1584 0.07065
112 12.630   20.76    0.09933     0.12090 0.1065000   0.060210   0.1735 0.07070
113 14.260   19.65    0.07837     0.22330 0.3003000   0.077980   0.1704 0.07769
114 10.510   20.19    0.11220     0.13030 0.0647600   0.030680   0.1922 0.07782
115  8.726   15.83    0.11500     0.08201 0.0413200   0.019240   0.1649 0.07633
116 11.930   21.53    0.09768     0.07849 0.0332800   0.020080   0.1688 0.06194
117  8.950   15.76    0.09462     0.12430 0.0926300   0.023080   0.1305 0.07163
118 14.870   16.67    0.11620     0.16490 0.1690000   0.089230   0.2157 0.06768
119 15.780   22.91    0.11550     0.17520 0.2133000   0.094790   0.2096 0.07331
120 17.950   20.01    0.08402     0.06722 0.0729300   0.055960   0.2129 0.05025
121 11.410   10.82    0.09373     0.06685 0.0351200   0.026230   0.1667 0.06113
122 18.660   17.12    0.10540     0.11000 0.1457000   0.086650   0.1966 0.06213
123 24.250   20.20    0.14470     0.28670 0.4268000   0.201200   0.2655 0.06877
124 14.500   10.89    0.11010     0.10990 0.0884200   0.057780   0.1856 0.06402
125 13.370   16.39    0.07115     0.07325 0.0809200   0.028000   0.1422 0.05823
126 13.850   17.21    0.08785     0.06136 0.0142000   0.011410   0.1614 0.05890
127 13.610   24.69    0.09258     0.07862 0.0528500   0.030850   0.1761 0.06130
128 19.000   18.91    0.08217     0.08028 0.0927100   0.056270   0.1946 0.05044
129 15.100   16.39    0.11500     0.18070 0.1138000   0.085340   0.2001 0.06467
130 19.790   25.12    0.10150     0.15890 0.2545000   0.114900   0.2202 0.06113
131 12.190   13.29    0.10660     0.09509 0.0285500   0.028820   0.1880 0.06471
132 15.460   19.48    0.10920     0.12230 0.1466000   0.080870   0.1931 0.05796
133 16.160   21.54    0.10080     0.12840 0.1043000   0.056130   0.2160 0.05891
134 15.710   13.93    0.09462     0.09462 0.0713500   0.059330   0.1816 0.05723
135 18.450   21.91    0.09430     0.09709 0.1153000   0.068470   0.1692 0.05727
136 12.770   22.47    0.09055     0.05761 0.0471100   0.027040   0.1585 0.06065
137 11.710   16.67    0.10510     0.06095 0.0359200   0.026000   0.1339 0.05945
138 11.430   15.39    0.09639     0.06889 0.0350300   0.028750   0.1734 0.05865
139 14.950   17.57    0.11670     0.13050 0.1539000   0.086240   0.1957 0.06216
140 11.280   13.39    0.11640     0.11360 0.0463500   0.047960   0.1771 0.06072
141  9.738   11.97    0.09250     0.04102 0.0000000   0.000000   0.1903 0.06422
142 16.110   18.05    0.09721     0.11370 0.0944700   0.059430   0.1861 0.06248
143 11.430   17.31    0.10920     0.09486 0.0203100   0.018610   0.1645 0.06562
144 12.900   15.92    0.08677     0.09509 0.0489400   0.030880   0.1778 0.06235
145 10.750   14.97    0.07793     0.05139 0.0225100   0.007875   0.1399 0.05688
146 11.900   14.65    0.11520     0.12960 0.0371000   0.030030   0.1995 0.07839
147 11.800   16.58    0.10910     0.17000 0.1659000   0.074150   0.2678 0.07371
148 14.950   18.77    0.08138     0.11670 0.0905000   0.035620   0.1744 0.06493
149 14.440   15.18    0.09970     0.10210 0.0848700   0.055320   0.1724 0.06081
150 13.740   17.91    0.07944     0.06376 0.0288100   0.013290   0.1473 0.05580
151 13.000   20.78    0.11350     0.07589 0.0313600   0.026450   0.2540 0.06087
152  8.219   20.70    0.09405     0.13050 0.1321000   0.021680   0.2222 0.08261
153  9.731   15.34    0.10720     0.15990 0.4108000   0.078570   0.2548 0.09296
154 11.150   13.08    0.09754     0.05113 0.0198200   0.017860   0.1830 0.06105
155 13.150   15.34    0.09384     0.08498 0.0929300   0.034830   0.1822 0.06207
156 12.250   17.94    0.08654     0.06679 0.0388500   0.023310   0.1970 0.06228
157 17.680   20.74    0.11150     0.16650 0.1855000   0.105400   0.1971 0.06166
158 16.840   19.46    0.07445     0.07223 0.0515000   0.027710   0.1844 0.05268
159 12.060   12.74    0.09311     0.05241 0.0197200   0.019630   0.1590 0.05907
160 10.900   12.96    0.07515     0.03718 0.0030900   0.006588   0.1442 0.05743
161 11.750   20.18    0.10890     0.11410 0.0684300   0.037380   0.1993 0.06453
162 19.190   15.94    0.08694     0.11850 0.1193000   0.096670   0.1741 0.05176
163 19.590   18.15    0.11200     0.16660 0.2508000   0.128600   0.2027 0.06082
164 12.340   22.22    0.10120     0.10150 0.0537000   0.028220   0.1551 0.06761
165 23.270   22.04    0.08439     0.11450 0.1324000   0.097020   0.1801 0.05553
166 14.970   19.76    0.08421     0.05352 0.0194700   0.019390   0.1515 0.05266
167 10.800    9.71    0.09594     0.05736 0.0253100   0.016980   0.1381 0.06400
168 16.780   18.80    0.08865     0.09182 0.0842200   0.065760   0.1893 0.05534
169 17.470   24.68    0.10490     0.16030 0.2159000   0.104300   0.1538 0.06365
170 14.970   16.95    0.09855     0.07885 0.0260200   0.037810   0.1780 0.05650
171 12.320   12.39    0.10280     0.06981 0.0398700   0.037000   0.1959 0.05955
172 13.430   19.63    0.09048     0.06288 0.0585800   0.034380   0.1598 0.05671
173 15.460   11.89    0.12570     0.15550 0.2032000   0.109700   0.1966 0.07069
174 11.080   14.71    0.10060     0.05743 0.0236300   0.025830   0.1566 0.06669
175 10.660   15.15    0.08792     0.04302 0.0000000   0.000000   0.1928 0.05975
176  8.671   14.45    0.09138     0.04276 0.0000000   0.000000   0.1722 0.06724
177  9.904   18.06    0.09699     0.12940 0.1307000   0.037160   0.1669 0.08116
178 16.460   20.11    0.09831     0.15560 0.1793000   0.088660   0.1794 0.06323
179 13.010   22.22    0.06251     0.01938 0.0015950   0.001852   0.1395 0.05234
180 12.810   13.06    0.08739     0.03774 0.0091930   0.013300   0.1466 0.06133
181 27.220   21.87    0.10940     0.19140 0.2871000   0.187800   0.1800 0.05770
182 21.090   26.57    0.11410     0.28320 0.2487000   0.149600   0.2395 0.07398
183 15.700   20.31    0.09597     0.08799 0.0659300   0.051890   0.1618 0.05549
184 11.410   14.92    0.09059     0.08155 0.0618100   0.023610   0.1167 0.06217
185 15.280   22.41    0.09057     0.10520 0.0537500   0.032630   0.1727 0.06317
186 10.080   15.11    0.09267     0.04695 0.0015970   0.002404   0.1703 0.06048
187 18.310   18.58    0.08588     0.08468 0.0816900   0.058140   0.1621 0.05425
188 11.710   17.19    0.09774     0.06141 0.0380900   0.032390   0.1516 0.06095
189 11.810   17.39    0.10070     0.05562 0.0235300   0.015530   0.1718 0.05780
190 12.300   15.90    0.08080     0.07253 0.0384400   0.016540   0.1667 0.05474
191 14.220   23.12    0.10750     0.24130 0.1981000   0.066180   0.2384 0.07542
192 12.770   21.41    0.08749     0.06601 0.0311200   0.028640   0.1694 0.06287
193  9.720   18.22    0.06950     0.02344 0.0000000   0.000000   0.1653 0.06447
194 12.340   26.86    0.10340     0.13530 0.1085000   0.045620   0.1943 0.06937
195 14.860   23.21    0.10440     0.19800 0.1697000   0.088780   0.1737 0.06672
196 12.910   16.33    0.07941     0.05366 0.0387300   0.023770   0.1829 0.05667
197 13.770   22.29    0.12000     0.12670 0.1385000   0.065260   0.1834 0.06877
198 18.080   21.84    0.07371     0.08642 0.1103000   0.057780   0.1770 0.05340
199 19.180   22.49    0.08523     0.14280 0.1114000   0.067720   0.1767 0.05529
200 14.450   20.22    0.09872     0.12060 0.1180000   0.059800   0.1950 0.06466
201 12.230   19.56    0.09586     0.08087 0.0418700   0.041070   0.1979 0.06013
202 17.540   19.32    0.08968     0.11980 0.1036000   0.074880   0.1506 0.05491
203 23.290   26.67    0.11410     0.20840 0.3523000   0.162000   0.2200 0.06229
204 13.810   23.75    0.13230     0.17680 0.1558000   0.091760   0.2251 0.07421
205 12.470   18.60    0.09965     0.10580 0.0800500   0.038210   0.1925 0.06373
206 15.120   16.68    0.08876     0.09588 0.0755000   0.040790   0.1594 0.05986
207  9.876   17.27    0.10890     0.07232 0.0175600   0.019520   0.1934 0.06285
208 17.010   20.26    0.08772     0.07304 0.0695000   0.053900   0.2026 0.05223
209 13.110   22.54    0.10020     0.14830 0.0870500   0.051020   0.1850 0.07310
210 15.270   12.91    0.08182     0.06230 0.0589200   0.031570   0.1359 0.05526
211 20.580   22.14    0.09090     0.13480 0.1640000   0.095610   0.1765 0.05024
212 11.840   18.94    0.08871     0.06900 0.0266900   0.013930   0.1533 0.06057
213 28.110   18.47    0.11420     0.15160 0.3201000   0.159500   0.1648 0.05525
214 17.420   25.56    0.10060     0.11460 0.1682000   0.065970   0.1308 0.05866
215 14.190   23.81    0.09463     0.13060 0.1115000   0.064620   0.2235 0.06433
216 13.860   16.93    0.10260     0.15170 0.0990100   0.056020   0.2106 0.06916
217 11.890   18.35    0.09363     0.11540 0.0663600   0.031420   0.1967 0.06314
218 10.200   17.48    0.08054     0.05907 0.0577400   0.010710   0.1964 0.06315
219 19.800   21.56    0.09383     0.13060 0.1272000   0.086910   0.2094 0.05581
220 19.530   32.47    0.08420     0.11300 0.1145000   0.066370   0.1428 0.05313
221 13.650   13.16    0.09646     0.08711 0.0388800   0.025630   0.1360 0.06344
222 13.560   13.90    0.10510     0.11920 0.0786000   0.044510   0.1962 0.06303
223 10.180   17.53    0.10610     0.08502 0.0176800   0.019150   0.1910 0.06908
224 15.750   20.25    0.10250     0.12040 0.1147000   0.064620   0.1935 0.06303
225 13.270   17.02    0.08445     0.04994 0.0355400   0.024560   0.1496 0.05674
226 14.340   13.47    0.09906     0.07624 0.0572400   0.046030   0.2075 0.05448
227 10.440   15.46    0.10530     0.07722 0.0066430   0.012160   0.1788 0.06450
228 15.000   15.51    0.08371     0.10960 0.0650500   0.037800   0.1881 0.05907
229 12.620   23.97    0.07903     0.07529 0.0543800   0.020360   0.1514 0.06019
230 12.830   22.33    0.10880     0.17990 0.1695000   0.068610   0.2123 0.07254
231 17.050   19.08    0.11410     0.15720 0.1910000   0.109000   0.2131 0.06325
232 11.320   27.08    0.06883     0.03813 0.0163300   0.003125   0.1869 0.05628
233 11.220   33.81    0.07780     0.03574 0.0049670   0.006434   0.1845 0.05828
234 20.510   27.81    0.09159     0.10740 0.1554000   0.083400   0.1448 0.05592
235  9.567   15.91    0.08464     0.04087 0.0165200   0.016670   0.1551 0.06403
236 14.030   21.25    0.09070     0.06945 0.0146200   0.018960   0.1517 0.05835
237 23.210   26.97    0.09509     0.16820 0.1950000   0.123700   0.1909 0.06309
238 20.480   21.46    0.08355     0.08348 0.0904200   0.060220   0.1467 0.05177
239 14.220   27.85    0.08223     0.10390 0.1103000   0.044080   0.1342 0.06129
240 17.460   39.28    0.09812     0.12980 0.1417000   0.088110   0.1809 0.05966
241 13.640   15.60    0.09423     0.06630 0.0470500   0.037310   0.1717 0.05660
242 12.420   15.04    0.07926     0.03393 0.0105300   0.011080   0.1546 0.05754
243 11.300   18.19    0.09592     0.13250 0.1548000   0.028540   0.2054 0.07669
244 13.750   23.77    0.08043     0.06807 0.0469700   0.023440   0.1773 0.05429
245 19.400   23.50    0.10270     0.15580 0.2049000   0.088860   0.1978 0.06000
246 10.480   19.86    0.10700     0.05971 0.0483100   0.030700   0.1737 0.06440
247 13.200   17.43    0.07215     0.04524 0.0433600   0.011050   0.1487 0.05635
248 12.890   14.11    0.08760     0.13460 0.1374000   0.039800   0.1596 0.06409
249 10.650   25.22    0.09657     0.07234 0.0237900   0.016150   0.1897 0.06329
250 11.520   14.93    0.10130     0.07808 0.0432800   0.029290   0.1883 0.06168
251 20.940   23.56    0.10070     0.16060 0.2712000   0.131000   0.2205 0.05898
252 11.500   18.45    0.09345     0.05991 0.0263800   0.020690   0.1834 0.05934
253 19.730   19.82    0.10620     0.18490 0.2417000   0.097400   0.1733 0.06697
254 17.300   17.08    0.10080     0.10410 0.1266000   0.083530   0.1813 0.05613
255 19.450   19.33    0.10350     0.11880 0.1379000   0.085910   0.1776 0.05647
256 13.960   17.05    0.10960     0.12790 0.0978900   0.052460   0.1908 0.06130
257 19.550   28.77    0.09260     0.20630 0.1784000   0.114400   0.1893 0.06232
258 15.320   17.27    0.13350     0.22840 0.2448000   0.124200   0.2398 0.07596
259 15.660   23.20    0.11090     0.31140 0.3176000   0.137700   0.2495 0.08104
260 15.530   33.56    0.10630     0.16390 0.1751000   0.083990   0.2091 0.06650
261 20.310   27.06    0.10000     0.10880 0.1519000   0.093330   0.1814 0.05572
262 17.350   23.06    0.08662     0.06290 0.0289100   0.028370   0.1564 0.05307
263 17.290   22.13    0.08999     0.12730 0.0969700   0.075070   0.2108 0.05464
264 15.610   19.38    0.07840     0.05616 0.0420900   0.028470   0.1547 0.05443
265 17.190   22.07    0.09726     0.08995 0.0906100   0.065270   0.1867 0.05580
266 20.730   31.12    0.09469     0.11430 0.1367000   0.086460   0.1769 0.05674
267 10.600   18.95    0.09688     0.11470 0.0638700   0.026420   0.1922 0.06491
268 13.590   21.84    0.07956     0.08259 0.0407200   0.021420   0.1635 0.05859
269 12.870   16.21    0.09425     0.06219 0.0390000   0.016150   0.2010 0.05769
270 10.710   20.39    0.10820     0.12890 0.0844800   0.028670   0.1668 0.06862
271 14.290   16.82    0.06429     0.02675 0.0072500   0.006250   0.1508 0.05376
272 11.290   13.04    0.09834     0.07608 0.0326500   0.027550   0.1769 0.06270
273 21.750   20.99    0.09401     0.19610 0.2195000   0.108800   0.1721 0.06194
274  9.742   15.67    0.09037     0.04689 0.0110300   0.014070   0.2081 0.06312
275 17.930   24.48    0.08855     0.07027 0.0569900   0.047440   0.1538 0.05510
276 11.890   17.36    0.12250     0.07210 0.0592900   0.074040   0.2015 0.05875
277 11.330   14.16    0.09379     0.03872 0.0014870   0.003333   0.1954 0.05821
278 18.810   19.98    0.08923     0.05884 0.0802000   0.058430   0.1550 0.04996
279 13.590   17.84    0.07948     0.04052 0.0199700   0.012380   0.1573 0.05520
280 13.850   15.18    0.09516     0.07688 0.0447900   0.037110   0.2110 0.05853
281 19.160   26.60    0.10200     0.14530 0.1921000   0.096640   0.1902 0.06220
282 11.740   14.02    0.07813     0.04340 0.0224500   0.027630   0.2101 0.06113
283 19.400   18.18    0.10370     0.14420 0.1626000   0.094640   0.1893 0.05892
284 16.240   18.77    0.10660     0.18020 0.1948000   0.090520   0.1876 0.06684
285 12.890   15.70    0.07818     0.09580 0.1115000   0.033900   0.1432 0.05935
286 12.580   18.40    0.08393     0.04216 0.0018600   0.002924   0.1697 0.05855
287 11.940   20.76    0.08605     0.10110 0.0657400   0.037910   0.1588 0.06766
288 12.890   13.12    0.06955     0.03729 0.0226000   0.011710   0.1337 0.05581
289 11.260   19.96    0.08020     0.11810 0.0927400   0.055880   0.2595 0.06233
290 11.370   18.89    0.08713     0.05008 0.0239900   0.021730   0.2013 0.05955
291 14.410   19.73    0.08757     0.16760 0.1362000   0.066020   0.1714 0.07192
292 14.960   19.10    0.08992     0.09823 0.0594000   0.048190   0.1879 0.05852
293 12.950   16.02    0.10050     0.07943 0.0615500   0.033700   0.1730 0.06470
294 11.850   17.46    0.08372     0.05642 0.0268800   0.022800   0.1875 0.05715
295 12.720   13.78    0.09667     0.08393 0.0128800   0.019240   0.1638 0.06100
296 13.770   13.27    0.09198     0.06221 0.0106300   0.019170   0.1592 0.05912
297 10.910   12.35    0.08518     0.04721 0.0123600   0.013690   0.1449 0.06031
298 11.760   18.14    0.09968     0.05914 0.0268500   0.035150   0.1619 0.06287
299 14.260   18.17    0.06576     0.05220 0.0247500   0.013740   0.1635 0.05586
300 10.510   23.09    0.10150     0.06797 0.0249500   0.018750   0.1695 0.06556
301 19.530   18.90    0.11500     0.16420 0.2197000   0.106200   0.1792 0.06552
302 12.460   19.89    0.08451     0.10140 0.0683000   0.030990   0.1781 0.06249
303 20.090   23.86    0.10800     0.18380 0.2283000   0.128000   0.2249 0.07469
304 10.490   18.61    0.10680     0.06678 0.0229700   0.017800   0.1482 0.06600
305 11.460   18.16    0.08853     0.07694 0.0334400   0.015020   0.1411 0.06243
306 11.600   24.49    0.07474     0.05688 0.0197400   0.013130   0.1935 0.05878
307 13.200   15.82    0.08511     0.05251 0.0014610   0.003261   0.1632 0.05894
308  9.000   14.40    0.07005     0.03116 0.0036810   0.003472   0.1788 0.06833
309 13.500   12.71    0.07376     0.03614 0.0027580   0.004419   0.1365 0.05335
310 13.050   13.84    0.08352     0.03735 0.0045590   0.008829   0.1453 0.05518
311 11.700   19.11    0.08814     0.05253 0.0158300   0.011480   0.1936 0.06128
312 14.610   15.69    0.07618     0.03515 0.0144700   0.018770   0.1632 0.05255
313 12.760   13.37    0.08794     0.07948 0.0405200   0.025480   0.1601 0.06140
314 11.540   10.72    0.08597     0.05969 0.0136700   0.008907   0.1833 0.06100
315  8.597   18.60    0.10740     0.05847 0.0000000   0.000000   0.2163 0.07359
316 12.490   16.85    0.08511     0.03834 0.0044730   0.006423   0.1215 0.05673
317 12.180   14.08    0.07734     0.03212 0.0112300   0.005051   0.1673 0.05649
318 18.220   18.87    0.09746     0.11170 0.1130000   0.079500   0.1807 0.05664
319  9.042   18.90    0.09968     0.19720 0.1975000   0.049080   0.2330 0.08743
320 12.430   17.00    0.07557     0.03454 0.0134200   0.016990   0.1472 0.05561
321 10.250   16.18    0.10610     0.11110 0.0672600   0.039650   0.1743 0.07279
322 20.160   19.66    0.08020     0.08564 0.1155000   0.077260   0.1928 0.05096
323 12.860   13.32    0.11340     0.08834 0.0380000   0.034000   0.1543 0.06476
324 20.340   21.51    0.11700     0.18750 0.2565000   0.150400   0.2569 0.06670
325 12.200   15.21    0.08673     0.06545 0.0199400   0.016920   0.1638 0.06129
326 12.670   17.30    0.10280     0.07664 0.0319300   0.021070   0.1707 0.05984
327 14.110   12.88    0.09309     0.05306 0.0176500   0.027330   0.1373 0.05700
328 12.030   17.93    0.07683     0.03892 0.0015460   0.005592   0.1382 0.06070
329 16.270   20.71    0.11690     0.13190 0.1478000   0.084880   0.1948 0.06277
330 16.260   21.88    0.11650     0.12830 0.1799000   0.079810   0.1869 0.06532
331 16.030   15.51    0.09491     0.13710 0.1204000   0.070410   0.1782 0.05976
332 12.980   19.35    0.09579     0.11250 0.0710700   0.029500   0.1761 0.06540
333 11.220   19.86    0.10540     0.06779 0.0050060   0.007583   0.1940 0.06028
334 11.250   14.78    0.08306     0.04458 0.0009737   0.002941   0.1773 0.06081
335 12.300   19.02    0.08313     0.04202 0.0077560   0.008535   0.1539 0.05945
336 17.060   21.00    0.11190     0.10560 0.1508000   0.099340   0.1727 0.06071
337 12.990   14.23    0.09462     0.09965 0.0373800   0.020980   0.1652 0.07238
338 18.770   21.43    0.09116     0.14020 0.1060000   0.060900   0.1953 0.06083
339 10.050   17.53    0.10070     0.07326 0.0251100   0.017750   0.1890 0.06331
340 23.510   24.27    0.10690     0.12830 0.2308000   0.141000   0.1797 0.05506
341 14.420   16.54    0.09751     0.11390 0.0800700   0.042230   0.1912 0.06412
342  9.606   16.84    0.08481     0.09228 0.0842200   0.022920   0.2036 0.07125
343 11.060   14.96    0.10330     0.09097 0.0539700   0.033410   0.1776 0.06907
344 19.680   21.68    0.09797     0.13390 0.1863000   0.110300   0.2082 0.05715
345 11.710   15.45    0.11500     0.07281 0.0400600   0.032500   0.2009 0.06506
346 10.260   14.71    0.09882     0.09159 0.0358100   0.020370   0.1633 0.07005
347 12.060   18.90    0.08386     0.05794 0.0075100   0.008488   0.1555 0.06048
348 14.760   14.74    0.08875     0.07780 0.0460800   0.035280   0.1521 0.05912
349 11.470   16.03    0.09076     0.05886 0.0258700   0.023220   0.1634 0.06372
350 11.950   14.96    0.11580     0.12060 0.0117100   0.017870   0.2459 0.06581
351 11.660   17.07    0.07561     0.03630 0.0083060   0.011620   0.1671 0.05731
352 15.750   19.22    0.12430     0.23640 0.2914000   0.124200   0.2375 0.07603
353 25.730   17.46    0.11490     0.23630 0.3368000   0.191300   0.1956 0.06121
354 15.080   25.74    0.10240     0.09769 0.1235000   0.065530   0.1647 0.06464
355 11.140   14.07    0.07274     0.06064 0.0450500   0.014710   0.1690 0.06083
356 12.560   19.07    0.08760     0.10380 0.1030000   0.043910   0.1533 0.06184
357 13.050   18.59    0.10820     0.13040 0.0960300   0.056030   0.2035 0.06501
358 13.870   16.21    0.08743     0.05492 0.0150200   0.020880   0.1424 0.05883
359  8.878   15.49    0.08293     0.07698 0.0472100   0.023810   0.1930 0.06621
360  9.436   18.32    0.10090     0.05956 0.0271000   0.014060   0.1506 0.06959
361 12.540   18.07    0.07436     0.02650 0.0011940   0.005449   0.1528 0.05185
362 13.300   21.57    0.08582     0.06373 0.0334400   0.024240   0.1815 0.05696
363 12.760   18.84    0.09676     0.07952 0.0268800   0.017810   0.1759 0.06183
364 16.500   18.29    0.09686     0.08468 0.0586200   0.048350   0.1495 0.05593
365 13.400   16.95    0.07937     0.05696 0.0218100   0.014730   0.1650 0.05701
366 20.440   21.78    0.09150     0.11310 0.0979900   0.077850   0.1618 0.05557
367 20.200   26.83    0.09905     0.16690 0.1641000   0.126500   0.1875 0.06020
368 12.210   18.02    0.09231     0.07175 0.0439200   0.020270   0.1695 0.05916
369 21.710   17.25    0.09384     0.08562 0.1168000   0.084650   0.1717 0.05054
370 22.010   21.90    0.10630     0.19540 0.2448000   0.150100   0.1824 0.06140
371 16.350   23.29    0.09742     0.14970 0.1811000   0.087730   0.2175 0.06218
372 15.190   13.21    0.07963     0.06934 0.0339300   0.026570   0.1721 0.05544
373 21.370   15.10    0.10010     0.15150 0.1932000   0.125500   0.1973 0.06183
374 20.640   17.35    0.09446     0.10760 0.1527000   0.089410   0.1571 0.05478
375 13.690   16.07    0.08302     0.06374 0.0255600   0.020310   0.1872 0.05669
376 16.170   16.07    0.09880     0.14380 0.0665100   0.053970   0.1990 0.06572
377 10.570   20.22    0.09073     0.16600 0.2280000   0.059410   0.2188 0.08450
378 13.460   28.21    0.07517     0.04726 0.0127100   0.011170   0.1421 0.05763
379 13.660   15.15    0.08268     0.07548 0.0424900   0.024710   0.1792 0.05897
380 11.080   18.83    0.12160     0.21540 0.1689000   0.063670   0.2196 0.07950
381 11.270   12.96    0.12370     0.11110 0.0790000   0.055500   0.2018 0.06914
382 11.040   14.93    0.07987     0.07079 0.0354600   0.020740   0.2003 0.06246
383 12.050   22.72    0.06935     0.10730 0.0794300   0.029780   0.1203 0.06659
384 12.390   17.48    0.10420     0.12970 0.0589200   0.028800   0.1779 0.06588
385 13.280   13.72    0.08363     0.08575 0.0507700   0.028640   0.1617 0.05594
386 14.600   23.29    0.08682     0.06636 0.0839000   0.052710   0.1627 0.05416
387 12.210   14.09    0.08108     0.07823 0.0683900   0.025340   0.1646 0.06154
388 13.880   16.16    0.07026     0.04831 0.0204500   0.008507   0.1607 0.05474
389 11.270   15.50    0.08365     0.11140 0.1007000   0.027570   0.1810 0.07252
390 19.550   23.21    0.10100     0.13180 0.1856000   0.102100   0.1989 0.05884
391 10.260   12.22    0.09996     0.07542 0.0192300   0.019680   0.1800 0.06569
392  8.734   16.84    0.10390     0.07428 0.0000000   0.000000   0.1985 0.07098
393 15.490   19.97    0.11600     0.15620 0.1891000   0.091130   0.1929 0.06744
394 21.610   22.28    0.11670     0.20870 0.2810000   0.156200   0.2162 0.06606
395 12.100   17.72    0.10290     0.09758 0.0478300   0.033260   0.1937 0.06161
396 14.060   17.18    0.08045     0.05361 0.0268100   0.032510   0.1641 0.05764
397 13.510   18.89    0.10590     0.11470 0.0858000   0.053810   0.1806 0.06079
398 12.800   17.46    0.08044     0.08895 0.0739000   0.040830   0.1574 0.05750
399 11.060   14.83    0.07741     0.04768 0.0271200   0.007246   0.1535 0.06214
400 11.800   17.26    0.09087     0.06232 0.0285300   0.016380   0.1847 0.06019
401 17.910   21.02    0.12300     0.25760 0.3189000   0.119800   0.2113 0.07115
402 11.930   10.91    0.08872     0.05242 0.0260600   0.017960   0.1601 0.05541
403 12.960   18.29    0.07351     0.07899 0.0405700   0.018830   0.1874 0.05899
404 12.940   16.17    0.09879     0.08836 0.0329600   0.023900   0.1735 0.06200
405 12.340   14.95    0.08682     0.04571 0.0210900   0.020540   0.1571 0.05708
406 10.940   18.59    0.10040     0.07460 0.0494400   0.029320   0.1486 0.06615
407 16.140   14.86    0.09495     0.08501 0.0550000   0.045280   0.1735 0.05875
408 12.850   21.37    0.07551     0.08316 0.0612600   0.018670   0.1580 0.06114
409 17.990   20.66    0.10360     0.13040 0.1201000   0.088240   0.1992 0.06069
410 12.270   17.92    0.08685     0.06526 0.0321100   0.026530   0.1966 0.05597
411 11.360   17.57    0.08858     0.05313 0.0278300   0.021000   0.1601 0.05913
412 11.040   16.83    0.10770     0.07804 0.0304600   0.024800   0.1714 0.06340
413  9.397   21.68    0.07969     0.06053 0.0373500   0.005128   0.1274 0.06724
414 14.990   22.11    0.08515     0.10250 0.0685900   0.038760   0.1944 0.05913
415 15.130   29.81    0.08320     0.04605 0.0468600   0.027390   0.1852 0.05294
416 11.890   21.17    0.09773     0.08120 0.0255500   0.021790   0.2019 0.06290
417  9.405   21.70    0.10440     0.06159 0.0204700   0.012570   0.2025 0.06601
418 15.500   21.08    0.11200     0.15710 0.1522000   0.084810   0.2085 0.06864
419 12.700   12.17    0.08785     0.05794 0.0236000   0.024020   0.1583 0.06275
420 11.160   21.41    0.10180     0.05978 0.0089550   0.010760   0.1615 0.06144
421 11.570   19.04    0.08546     0.07722 0.0548500   0.014280   0.2031 0.06267
422 14.690   13.98    0.10310     0.18360 0.1450000   0.063000   0.2086 0.07406
423 11.610   16.02    0.10880     0.11680 0.0709700   0.044970   0.1886 0.06320
424 13.660   19.13    0.09057     0.11470 0.0965700   0.048120   0.1848 0.06181
425  9.742   19.12    0.10750     0.08333 0.0089340   0.019670   0.2538 0.07029
426 10.030   21.28    0.08117     0.03912 0.0024700   0.005159   0.1630 0.06439
427 10.480   14.98    0.09816     0.10130 0.0633500   0.022180   0.1925 0.06915
428 10.800   21.98    0.08801     0.05743 0.0361400   0.014040   0.2016 0.05977
429 11.130   16.62    0.08151     0.03834 0.0136900   0.013700   0.1511 0.06148
430 12.720   17.67    0.07896     0.04522 0.0140200   0.018350   0.1459 0.05544
431 14.900   22.53    0.09947     0.22250 0.2733000   0.097110   0.2041 0.06898
432 12.400   17.68    0.10540     0.13160 0.0774100   0.027990   0.1811 0.07102
433 20.180   19.54    0.11330     0.14890 0.2133000   0.125900   0.1724 0.06053
434 18.820   21.97    0.10180     0.13890 0.1594000   0.087440   0.1943 0.06132
435 14.860   16.94    0.08924     0.07074 0.0334600   0.028770   0.1573 0.05703
436 13.980   19.62    0.10600     0.11330 0.1126000   0.064630   0.1669 0.06544
437 12.870   19.54    0.09136     0.07883 0.0179700   0.020900   0.1861 0.06347
438 14.040   15.98    0.08458     0.05895 0.0353400   0.029440   0.1714 0.05898
439 13.850   19.60    0.08684     0.06330 0.0134200   0.022930   0.1555 0.05673
440 14.020   15.66    0.07966     0.05581 0.0208700   0.026520   0.1589 0.05586
441 10.970   17.20    0.08915     0.11130 0.0945700   0.036130   0.1489 0.06640
442 17.270   25.42    0.08331     0.11090 0.1204000   0.057360   0.1467 0.05407
443 13.780   15.79    0.08817     0.06718 0.0105500   0.009937   0.1405 0.05848
444 10.570   18.32    0.08142     0.04462 0.0199300   0.011110   0.2372 0.05768
445 18.030   16.85    0.08947     0.12320 0.1090000   0.062540   0.1720 0.05780
446 11.990   24.89    0.10300     0.09218 0.0544100   0.042740   0.1820 0.06850
447 17.750   28.03    0.09997     0.13140 0.1698000   0.082930   0.1713 0.05916
448 14.800   17.66    0.09179     0.08890 0.0406900   0.022600   0.1893 0.05886
449 14.530   19.34    0.08388     0.07800 0.0881700   0.029250   0.1473 0.05746
450 21.100   20.52    0.09684     0.11750 0.1572000   0.115500   0.1554 0.05661
451 11.870   21.54    0.06613     0.10640 0.0877700   0.023860   0.1349 0.06612
452 19.590   25.00    0.10320     0.09871 0.1655000   0.090630   0.1663 0.05391
453 12.000   28.23    0.08437     0.06450 0.0405500   0.019450   0.1615 0.06104
454 14.530   13.98    0.10990     0.09242 0.0689500   0.064950   0.1650 0.06121
455 12.620   17.15    0.08583     0.05430 0.0296600   0.022720   0.1799 0.05826
456 13.380   30.72    0.09245     0.07426 0.0281900   0.032640   0.1375 0.06016
457 11.630   29.29    0.09357     0.08574 0.0716000   0.020170   0.1799 0.06166
458 13.210   25.25    0.08791     0.05205 0.0277200   0.020680   0.1619 0.05584
459 13.000   25.13    0.08369     0.05073 0.0120600   0.017620   0.1667 0.05449
460  9.755   28.20    0.07984     0.04626 0.0154100   0.010430   0.1621 0.05952
461 17.080   27.15    0.09898     0.11100 0.1007000   0.064310   0.1793 0.06281
462 27.420   26.27    0.10840     0.19880 0.3635000   0.168900   0.2061 0.05623
463 14.400   26.99    0.06995     0.05223 0.0347600   0.017370   0.1707 0.05433
464 11.600   18.36    0.08508     0.05855 0.0336700   0.017770   0.1516 0.05859
465 13.170   18.22    0.07466     0.05994 0.0485900   0.028700   0.1454 0.05549
466 13.240   20.13    0.08284     0.12230 0.1010000   0.028330   0.1601 0.06432
467 13.140   20.74    0.08675     0.10890 0.1085000   0.035100   0.1562 0.06020
468  9.668   18.10    0.08311     0.05428 0.0147900   0.005769   0.1680 0.06412
469 17.600   23.33    0.09289     0.20040 0.2136000   0.100200   0.1696 0.07369
470 11.620   18.18    0.11750     0.14830 0.1020000   0.055640   0.1957 0.07255
471  9.667   18.49    0.08946     0.06258 0.0294800   0.015140   0.2238 0.06413
472 12.040   28.14    0.08752     0.06000 0.0236700   0.023770   0.1854 0.05698
473 14.920   14.93    0.08098     0.08549 0.0553900   0.032210   0.1687 0.05669
474 12.270   29.97    0.07699     0.03398 0.0000000   0.000000   0.1701 0.05960
475 10.880   15.62    0.10070     0.10690 0.0511500   0.015710   0.1861 0.06837
476 12.830   15.73    0.09040     0.08269 0.0583500   0.030780   0.1705 0.05913
477 14.200   20.53    0.08931     0.11080 0.0506300   0.030580   0.1506 0.06009
478 13.900   16.62    0.06828     0.05319 0.0222400   0.013390   0.1813 0.05536
479 11.490   14.59    0.10460     0.08228 0.0530800   0.019690   0.1779 0.06574
480 16.250   19.51    0.10260     0.18930 0.2236000   0.091940   0.2151 0.06578
481 12.160   18.03    0.09087     0.07838 0.0291600   0.015270   0.1464 0.06284
482 13.900   19.24    0.07991     0.05326 0.0299500   0.020700   0.1579 0.05594
483 13.470   14.06    0.10710     0.11550 0.0578600   0.052660   0.1779 0.06639
484 13.700   17.64    0.09950     0.07957 0.0454800   0.031600   0.1732 0.06088
485 15.730   11.28    0.10430     0.12990 0.1191000   0.062110   0.1784 0.06259
486 12.450   16.41    0.09514     0.15110 0.1544000   0.048460   0.2082 0.07325
487 14.640   16.85    0.08641     0.06698 0.0519200   0.027910   0.1409 0.05355
488 19.440   18.82    0.10890     0.14480 0.2256000   0.119400   0.1823 0.06115
489 11.680   16.17    0.11280     0.09263 0.0427900   0.031320   0.1853 0.06401
490 16.690   20.20    0.07497     0.07112 0.0364900   0.023070   0.1846 0.05325
491 12.250   22.44    0.08192     0.05200 0.0171400   0.012610   0.1544 0.05976
492 17.850   13.23    0.07838     0.06217 0.0444500   0.041780   0.1220 0.05243
493 18.010   20.56    0.10010     0.12890 0.1170000   0.077620   0.2116 0.06077
494 12.460   12.83    0.07372     0.04043 0.0071730   0.011490   0.1613 0.06013
495 13.160   20.54    0.07335     0.05275 0.0180000   0.012560   0.1713 0.05888
496 14.870   20.21    0.09587     0.08345 0.0682400   0.049510   0.1487 0.05748
497 12.650   18.17    0.10760     0.13340 0.0801700   0.050740   0.1641 0.06854
498 12.470   17.31    0.08928     0.07630 0.0360900   0.023690   0.1526 0.06046
499 18.490   17.52    0.10120     0.13170 0.1491000   0.091830   0.1832 0.06697
500 20.590   21.24    0.10850     0.16440 0.2188000   0.112100   0.1848 0.06222
501 15.040   16.74    0.09883     0.13640 0.0772100   0.061420   0.1668 0.06869
502 13.820   24.49    0.11620     0.16810 0.1357000   0.067590   0.2275 0.07237
503 12.540   16.32    0.11580     0.10850 0.0592800   0.032790   0.1943 0.06612
504 23.090   19.83    0.09342     0.12750 0.1676000   0.100300   0.1505 0.05484
505  9.268   12.87    0.16340     0.22390 0.0973000   0.052520   0.2378 0.09502
506  9.676   13.14    0.12550     0.22040 0.1188000   0.070380   0.2057 0.09575
507 12.220   20.04    0.10960     0.11520 0.0817500   0.021660   0.2124 0.06894
508 11.060   17.12    0.11940     0.10710 0.0406300   0.042680   0.1954 0.07976
509 16.300   15.70    0.09427     0.06712 0.0552600   0.045630   0.1711 0.05657
510 15.460   23.95    0.11830     0.18700 0.2030000   0.085200   0.1807 0.07083
511 11.740   14.69    0.08099     0.09661 0.0672600   0.026390   0.1499 0.06758
512 14.810   14.70    0.08472     0.05016 0.0341600   0.025410   0.1659 0.05348
513 13.400   20.52    0.11060     0.14690 0.1445000   0.081720   0.2116 0.07325
514 14.580   13.66    0.09832     0.08918 0.0822200   0.043490   0.1739 0.05640
515 15.050   19.07    0.09215     0.08597 0.0748600   0.043350   0.1561 0.05915
516 11.340   18.61    0.10490     0.08499 0.0430200   0.025940   0.1927 0.06211
517 18.310   20.58    0.10680     0.12480 0.1569000   0.094510   0.1860 0.05941
518 19.890   20.26    0.10370     0.13100 0.1411000   0.094310   0.1802 0.06188
519 12.880   18.22    0.12180     0.16610 0.0482500   0.053030   0.1709 0.07253
520 12.750   16.70    0.11250     0.11170 0.0388000   0.029950   0.2120 0.06623
521  9.295   13.90    0.13710     0.12250 0.0333200   0.024210   0.2197 0.07696
522 24.630   21.60    0.10300     0.21060 0.2310000   0.147100   0.1991 0.06739
523 11.260   19.83    0.08511     0.04413 0.0050670   0.005664   0.1637 0.06343
524 13.710   18.68    0.09916     0.10700 0.0538500   0.037830   0.1714 0.06843
525  9.847   15.68    0.09492     0.08419 0.0233000   0.024160   0.1387 0.06891
526  8.571   13.10    0.10360     0.07632 0.0256500   0.015100   0.1678 0.07126
527 13.460   18.75    0.10750     0.11380 0.0420100   0.031520   0.1723 0.06317
528 12.340   12.27    0.09003     0.06307 0.0295800   0.026470   0.1689 0.05808
529 13.940   13.17    0.12480     0.09755 0.1010000   0.066150   0.1976 0.06457
530 12.070   13.44    0.11000     0.09009 0.0378100   0.027980   0.1657 0.06608
531 11.750   17.56    0.10730     0.09713 0.0528200   0.044400   0.1598 0.06677
532 11.670   20.02    0.10160     0.09453 0.0420000   0.021570   0.1859 0.06461
533 13.680   16.33    0.09277     0.07255 0.0175200   0.018800   0.1631 0.06155
534 20.470   20.67    0.09156     0.13130 0.1523000   0.101500   0.2166 0.05419
535 10.960   17.62    0.09687     0.09752 0.0526300   0.027880   0.1619 0.06408
536 20.550   20.86    0.10460     0.17390 0.2085000   0.132200   0.2127 0.06251
537 14.270   22.55    0.10380     0.11540 0.1463000   0.061390   0.1926 0.05982
538 11.690   24.44    0.12360     0.15520 0.0451500   0.045310   0.2131 0.07405
539  7.729   25.49    0.08098     0.04878 0.0000000   0.000000   0.1870 0.07285
540  7.691   25.44    0.08668     0.11990 0.0925200   0.013640   0.2037 0.07751
541 11.540   14.44    0.09984     0.11200 0.0673700   0.025940   0.1818 0.06782
542 14.470   24.99    0.08837     0.12300 0.1009000   0.038900   0.1872 0.06341
543 14.740   25.42    0.08275     0.07214 0.0410500   0.030270   0.1840 0.05680
544 13.210   28.06    0.08671     0.06877 0.0298700   0.032750   0.1628 0.05781
545 13.870   20.70    0.09578     0.10180 0.0368800   0.023690   0.1620 0.06688
546 13.620   23.23    0.09246     0.06747 0.0297400   0.024430   0.1664 0.05801
547 10.320   16.35    0.09434     0.04994 0.0101200   0.005495   0.1885 0.06201
548 10.260   16.58    0.08877     0.08066 0.0435800   0.024380   0.1669 0.06714
549  9.683   19.34    0.08491     0.05030 0.0233700   0.009615   0.1580 0.06235
550 10.820   24.21    0.08192     0.06602 0.0154800   0.008160   0.1976 0.06328
551 10.860   21.48    0.07431     0.04227 0.0000000   0.000000   0.1661 0.05948
552 11.130   22.44    0.09566     0.08194 0.0482400   0.022570   0.2030 0.06552
553 12.770   29.43    0.08276     0.04234 0.0199700   0.014990   0.1539 0.05637
554  9.333   21.94    0.09240     0.05605 0.0399600   0.012820   0.1692 0.06576
555 12.880   28.92    0.08123     0.05824 0.0619500   0.023430   0.1566 0.05708
556 10.290   27.61    0.09030     0.07658 0.0599900   0.027380   0.1593 0.06127
557 10.160   19.59    0.10030     0.07504 0.0050250   0.011160   0.1791 0.06331
558  9.423   27.88    0.08123     0.04971 0.0000000   0.000000   0.1742 0.06059
559 14.590   22.68    0.08473     0.13300 0.1029000   0.037360   0.1454 0.06147
560 11.510   23.93    0.09261     0.10210 0.1112000   0.041050   0.1388 0.06570
561 14.050   27.15    0.09929     0.11260 0.0446200   0.043040   0.1537 0.06171
562 11.200   29.37    0.07449     0.03558 0.0000000   0.000000   0.1060 0.05502
563 15.220   30.62    0.10480     0.20870 0.2550000   0.094290   0.2128 0.07152
564 20.920   25.09    0.10990     0.22360 0.3174000   0.147400   0.2149 0.06879
565 21.560   22.39    0.11100     0.11590 0.2439000   0.138900   0.1726 0.05623
566 20.130   28.25    0.09780     0.10340 0.1440000   0.097910   0.1752 0.05533
567 16.600   28.08    0.08455     0.10230 0.0925100   0.053020   0.1590 0.05648
568 20.600   29.33    0.11780     0.27700 0.3514000   0.152000   0.2397 0.07016
569  7.760   24.54    0.05263     0.04362 0.0000000   0.000000   0.1587 0.05884

A.

My analysis suggests 3 PCs should be retained. Support or refute this suggestion. What percent of variability is explained by the first 3 PCs?

#Getting the loadings 

bc_cells_pca <- prcomp(bc_cells_cols, scale. = TRUE)

bc_cells_pca 
Standard deviations (1, .., p=8):
[1] 2.0705378 1.3503646 0.9086939 0.7061387 0.6101579 0.3035518 0.2622598
[8] 0.1783697

Rotation (n x k) = (8 x 8):
                   PC1         PC2         PC3           PC4         PC5
Radius      -0.3003952  0.52850910  0.27751200 -0.0449523963  0.04245937
Texture     -0.1432175  0.35378530 -0.89839046 -0.0002176232  0.21581443
Smoothness  -0.3482386 -0.32661945  0.12684205  0.1097614573  0.84332416
Compactness -0.4584098 -0.07219238 -0.02956419  0.1825835334 -0.23762997
Concavity   -0.4508935  0.12707085  0.04245883  0.1571126948 -0.30459047
ConcavePts  -0.4459288  0.22823091  0.17458320  0.0608428515  0.01923459
Symmetry    -0.3240333 -0.28112508 -0.08456832 -0.8897711849 -0.11359240
FracDim     -0.2251375 -0.57996072 -0.24389523  0.3640273309 -0.27912206
                     PC6         PC7          PC8
Radius      -0.518437923  0.36152546 -0.387460874
Texture     -0.006127134  0.02418201  0.004590238
Smoothness   0.079444068 -0.04732075 -0.155456892
Compactness -0.388065805 -0.73686177  0.020239147
Concavity    0.700061530  0.02347868 -0.413095816
ConcavePts   0.125314641  0.21313047  0.808318445
Symmetry    -0.018262848  0.05764443 -0.023810142
FracDim     -0.261064577  0.52365191 -0.026129456
fviz_eig(bc_cells_pca)
Warning in geom_bar(stat = "identity", fill = barfill, color = barcolor, :
Ignoring empty aesthetic: `width`.

bc_cells_pca$sdev^2
[1] 4.28712664 1.82348458 0.82572454 0.49863192 0.37229268 0.09214368 0.06878019
[8] 0.03181576
#4.28712664 1.82348458 0.82572454 0.49863192 0.37229268 0.09214368
#0.06878019 0.03181576

#4.28712664 1.82348458 0.82572454 0.49863192 0.37229268 0.09214368
#0.06878019 0.03181576  
#Total is 7.999

#First PCs are 4.287 + 1.824 + 0.826 = 6.937

#6.937 / 7.99 = 0.867 and 86.7%
#I would refute that suggestion that the first 3 PCs as they  
#only explain 86.7% of the variability. Short of the 90% 
#variability threshold which we want for, when we chose 
#how many PCs we want to use.
#
#

B.

Interpret the first 3 principal components by examining the eigenvectors/loadings. Discuss.

loadings <- bc_cells_pca$rotation
loadings
                   PC1         PC2         PC3           PC4         PC5
Radius      -0.3003952  0.52850910  0.27751200 -0.0449523963  0.04245937
Texture     -0.1432175  0.35378530 -0.89839046 -0.0002176232  0.21581443
Smoothness  -0.3482386 -0.32661945  0.12684205  0.1097614573  0.84332416
Compactness -0.4584098 -0.07219238 -0.02956419  0.1825835334 -0.23762997
Concavity   -0.4508935  0.12707085  0.04245883  0.1571126948 -0.30459047
ConcavePts  -0.4459288  0.22823091  0.17458320  0.0608428515  0.01923459
Symmetry    -0.3240333 -0.28112508 -0.08456832 -0.8897711849 -0.11359240
FracDim     -0.2251375 -0.57996072 -0.24389523  0.3640273309 -0.27912206
                     PC6         PC7          PC8
Radius      -0.518437923  0.36152546 -0.387460874
Texture     -0.006127134  0.02418201  0.004590238
Smoothness   0.079444068 -0.04732075 -0.155456892
Compactness -0.388065805 -0.73686177  0.020239147
Concavity    0.700061530  0.02347868 -0.413095816
ConcavePts   0.125314641  0.21313047  0.808318445
Symmetry    -0.018262848  0.05764443 -0.023810142
FracDim     -0.261064577  0.52365191 -0.026129456
bc_cells_PC1 <- loadings[,1] 

bc_cells_PC2 <- loadings[,2]

bc_cells_PC3 <- loadings[,3]

bc_cells_PC1
     Radius     Texture  Smoothness Compactness   Concavity  ConcavePts 
 -0.3003952  -0.1432175  -0.3482386  -0.4584098  -0.4508935  -0.4459288 
   Symmetry     FracDim 
 -0.3240333  -0.2251375 
#bc_cells_PC1
#     Radius     Texture  Smoothness Compactness   Concavity 
# -0.3003952  -0.1432175  -0.3482386  -0.4584098  -0.4508935 
# ConcavePts    Symmetry     FracDim 
# -0.4459288  -0.3240333  -0.2251375 

#Our biggest contributers (we don't take into account the sign 
#of the variable) to PC1 are compactness, concavity, concavepts, #symmetry. Tumors with rough texture & irregularity will
#have 



bc_cells_PC2
     Radius     Texture  Smoothness Compactness   Concavity  ConcavePts 
 0.52850910  0.35378530 -0.32661945 -0.07219238  0.12707085  0.22823091 
   Symmetry     FracDim 
-0.28112508 -0.57996072 
#    Radius     Texture  Smoothness Compactness   Concavity 
# 0.52850910  0.35378530 -0.32661945 -0.07219238  0.12707085 
# ConcavePts    Symmetry     FracDim 
# 0.22823091 -0.28112508 -0.57996072 


#Our biggest contributers ( the sign of the variables don't matter again) to PC2 are Radius, FracDim, Texture, Smoothness, 
#ConcavePts. We can infer that tumors with bigger radius and #fractal dimensions will contribute the most to PC2. 


bc_cells_PC3
     Radius     Texture  Smoothness Compactness   Concavity  ConcavePts 
 0.27751200 -0.89839046  0.12684205 -0.02956419  0.04245883  0.17458320 
   Symmetry     FracDim 
-0.08456832 -0.24389523 
#Radius     Texture  Smoothness  Compactness   Concavity 
# 0.27751200 -0.89839046  0.12684205 -0.02956419  0.04245883 
#ConcavePts    Symmetry     FracDim 
# 0.17458320 -0.08456832 -0.24389523 

#Our biggest contributers to PC3 are Radius, Texture, FracDim,  #ConcavePts. We can infer that this too means that for the PC3 #dimension tumors with less textures (because its negative) & larger radius, multiple #fractures (FracDim) contribute the most to the PC3 dimension. 
#Texture plays a disproportiate role, meaning that less texture
#more easily sways the PC3 value dimension.  

C.

Examine a biplot of the first two PCs. Incorporate the third PC by sizing the points by this variable. (Hint: use fviz_pca to set up a biplot, but set col.ind='white'. Then use geom_point() to maintain full control over the point mapping.) Color-code by whether the cells are benign or malignant. Answer the following:

  • What characteristics distinguish malignant from benign cells?

  • Of the 3 PCs, which does the best job of differentiating malignant from benign cells?

scores <- as.data.frame(bc_cells_pca$x)
colnames(scores) <- paste0("PC", 1:ncol(scores))

scores$Diagnosis <- bc_cells$Diagnosis


# Build the base biplot using fviz_pca but hide its points
p <- fviz_pca_biplot(
  bc_cells_pca,
  col.ind = "white",     # hide original points
  geom = "point",
  repel = TRUE,
  col.var = "black"
)

# Add your own points scaled by PC3
p +
  geom_point(
    data = scores,
    aes(x = PC1, y = PC2, color = Diagnosis, size = PC3),
    alpha = 0.6
  ) +
  scale_size_continuous(name = "PC3 (size)") +
  scale_color_manual(values = c("B" = "steelblue", "M" = "firebrick")) +
  theme_minimal() +
  labs(title = "Biplot of First Two PCs (Size by PC3 & Diagnosis by Color)")

#Looking at the biplot and where the points are stationed by 
#their color  and size we can say that the characteristics that 
#most underscore the differences between benign & malignant #tumors were Radius, Texture, ConcavePts, Concavity, Compactness
#
#We can say that for full certainity that PC1 is by far the strongest in terms of how much of a impact it has on #differentiating malignant & benign tumors. Numerically it 
#explains 53.6% of the variability and visually we see a clearer 
#split on the horizontal axis. On the other hand PC2 explains 
#far less variability and it isn't as clear cut how different 
#the two are on the vertical axis. Meanwhile PC3 comes out  #slightly stronger than PC2 with the difference in size of the
#points being somewhat obvious (but hard to differentiate) and
#explaining slightly more in variability.