Skip to content
iPASTIC calculates the 14 yield-based stress indices as defined in iPASTIC: online plant abiotic stress index calculator.
R
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Examples.zip
README.md
Screenshot 1.jpg
Screenshot 2.jpg
Screenshot 3.jpg
Screenshot 4.jpg
Screenshot 5.jpg
Screenshot 6.jpg
iPASTIC.R

README.md

How to use iPASTIC in R

iPASTIC calculates the 14 yield-based stress indices as defined in iPASTIC: an online toolkit to calculate plant abiotic stress indices.

Step 1: Loading the library

To get started, execute the library code (iPASTIC.R) in your RStudio console.

Step 2: Loading the data

After execution, function Calculate can be used to get the results. It takes a dataframe as input and returns the result as an object containing dataframes result$indices, result$ranks and correlation matrixes results$correlations$pearson and results$correlations$spearman.

First, you need to convert your data to a dataframe (given that the data is already like example provided here).

Option 1: Copy data from your favorite app and get it from clipboard

1. Copy data as table in your favorite app

Copying table data from excel

2. Execute the following command in your RStudio console

df <- read.delim("clipboard")

Option 2: Read from Excel file directly

1. Install XLConnect library

install.packages("XLConnect")

2. Load XLConnect library

library("XLConnect")

3. Load data from xlsx file

df <- readWorksheetFromFile("<Path to .xlsx file>", sheet=1)

Step 3: Getting the results

The table data in df variable should now look like the following:

> df
   genotype.code    Yp    Ys
1             G1 66.12 53.51
2             G2 86.85 75.18
3             G3 98.65 84.38
4             G4 74.23 35.11
5             G5 63.35 54.70
6             G6 74.43 49.42
7             G7 63.66 49.17
8             G8 85.61 59.08
9             G9 86.34 59.89
10           G10 74.34 56.07
11           G11 43.32 28.16
12           G12 60.46 43.70
13           G13 54.76 45.54
14           G14 60.88 37.26
15           G15 57.20 42.90
16           G16 58.79 54.65
17           G17 54.30 43.15
18           G18 62.29 58.08
19           G19 62.04 49.29
20           G20 88.51 74.00
21           G21 78.98 48.15
22           G22 51.82 35.39
23           G23 45.76 42.10
24           G24 53.22 33.52
25           G25 90.88 42.08
26           G26 51.04 32.13
27           G27 51.72 45.63
28           G28 42.66 34.14
29           G29 60.81 29.75
30           G30 88.35 50.05
31           G31 55.20 47.03
32           G32 68.46 53.20
33           G33 56.51 45.59
34           G34 72.70 26.28
35           G35 61.96 44.84
36           G36 55.70 43.32
37           G37 57.75 43.01
38           G38 72.31 35.63
39           G39 62.03 41.56
40           G40 69.91 53.08
41           G41 58.43 47.98
42           G42 55.98 48.90
43           G43 77.42 55.97
44           G44 67.42 54.15
45           G45 77.62 61.61
46           G46 75.23 71.12
47           G47 79.13 77.13
48           G48 76.53 59.77
49           G49 77.80 55.71
50           G50 83.28 65.80
51           G51 61.66 40.22
52           G52 58.52 45.56
53           G53 69.44 54.03
54           G54 66.32 55.73
55           G55 51.65 50.52
56           G56 60.55 35.60
57           G57 64.12 46.85
58           G58 55.12 50.31
59           G59 85.98 41.22
60           G60 55.06 36.03
61           G61 81.73 56.26
62           G62 61.58 52.85
63           G63 63.23 49.69
64           G64 59.77 56.07
65           G65 73.23 54.83
66           G66 67.80 43.99
67           G67 66.59 49.13
68           G68 74.55 51.53
69           G69 58.01 56.35
70           G70 57.23 30.73
71           G71 52.07 49.68
72           G72 46.97 41.11
73           G73 62.65 39.03
74           G74 54.65 48.93
75           G75 51.69 36.43
76           G76 57.99 31.59
77           G77 54.36 40.02
78           G78 42.77 25.43
79           G79 53.03 32.72
80           G80 50.24 44.14
81           G81 37.65 31.13
82           G82 53.15 39.33
83           G83 75.95 57.50
84           G84 62.28 50.11
85           G85 70.50 40.43
86           G86 61.00 53.15
87           G87 54.81 35.77
88           G88 99.08 28.87
89           G89 56.64 50.93
90           G90 66.32 53.03

1. Use Calculate function to get the output

results <- Calculate(df)

2. Get the output values available in results variable (results$indices and results$ranks)

> results$indices
       Yp    Ys        RC   TOL     MP      GMP       HM        SSI       STI        YI       YSI       RSI
G1  66.12 53.51 19.071385 12.61 59.815 59.48177 59.15040 0.71748894 0.8493719 1.1292497 0.8092861 1.1022804
G2  86.85 75.18 13.436960 11.67 81.015 80.80460 80.59474 0.50551495 1.5674809 1.5865631 0.8656304 1.1790236
G3  98.65 84.38 14.465281 14.27 91.515 91.23643 90.95872 0.54420165 1.9983278 1.7807156 0.8553472 1.1650174
G4  74.23 35.11 52.701064 39.12 54.670 51.05110 47.67176 1.98267876 0.6256629 0.7409448 0.4729894 0.6442306
G5  63.35 54.70 13.654301  8.65 59.025 58.86633 58.70809 0.51369159 0.8318865 1.1543629 0.8634570 1.1760633
G6  74.43 49.42 33.602042 25.01 61.925 60.64924 59.39977 1.26415009 0.8830410 1.0429363 0.6639796 0.9043670
G7  63.66 49.17 22.761546 14.49 56.415 55.94785 55.48457 0.85631730 0.7514446 1.0376604 0.7723845 1.0520189
G8  85.61 59.08 30.989370 26.53 72.345 71.11848 69.91276 1.16585817 1.2142136 1.2467964 0.6901063 0.9399526
G9  86.34 59.89 30.634700 26.45 73.115 71.90899 70.72287 1.15251504 1.2413564 1.2638902 0.6936530 0.9447834
G10 74.34 56.07 24.576271 18.27 65.205 64.56194 63.92522 0.92458950 1.0006524 1.1832748 0.7542373 1.0273016
G11 43.32 28.16 34.995383 15.16 35.740 34.92694 34.13238 1.31656929 0.2928540 0.5942753 0.6500462 0.8853891
G12 60.46 43.70 27.720807 16.76 52.080 51.40138 50.73161 1.04289081 0.6342781 0.9222241 0.7227919 0.9844718
G13 54.76 45.54 16.837107  9.22 50.150 49.93767 49.72623 0.63343266 0.5986687 0.9610546 0.8316289 1.1327122
G14 60.88 37.26 38.797635 23.62 49.070 47.62761 46.22761 1.45961467 0.5445623 0.7863174 0.6120237 0.8336009
G15 57.20 42.90 25.000000 14.30 50.050 49.53665 49.02857 0.94053070 0.5890924 0.9053413 0.7500000 1.0215303
G16 58.79 54.65  7.042014  4.14 56.720 56.68222 56.64446 0.26492921 0.7713007 1.1533077 0.9295799 1.2661253
G17 54.30 43.15 20.534070 11.15 48.725 48.40501 48.08712 0.77251693 0.5624847 0.9106172 0.7946593 1.0823581
G18 62.29 58.08  6.758709  4.21 60.185 60.14818 60.11138 0.25427094 0.8685105 1.2256928 0.9324129 1.2699840
G19 62.04 49.29 20.551257 12.75 55.665 55.29875 54.93491 0.77316354 0.7341093 1.0401928 0.7944874 1.0821240
G20 88.51 74.00 16.393628 14.51 81.255 80.93046 80.60722 0.61674841 1.5723679 1.5616610 0.8360637 1.1387526
G21 78.98 48.15 39.035199 30.83 63.565 61.66755 59.82674 1.46855212 0.9129427 1.0161348 0.6096480 0.8303652
G22 51.82 35.39 31.705905 16.43 43.605 42.82417 42.05733 1.19281509 0.4402588 0.7468538 0.6829409 0.9301932
G23 45.76 42.10  7.998252  3.66 43.930 43.89187 43.85377 0.30090405 0.4624856 0.8884585 0.9200175 1.2531010
G24 53.22 33.52 37.016159 19.70 43.370 42.23665 41.13291 1.39259337 0.4282615 0.7073902 0.6298384 0.8578653
G25 90.88 42.08 53.697183 48.80 66.480 61.84036 57.52452 2.02015397 0.9180666 0.8880364 0.4630282 0.6306631
G26 51.04 32.13 37.049373 18.91 41.585 40.49587 39.43526 1.39384291 0.3936874 0.6780563 0.6295063 0.8574130
G27 51.72 45.63 11.774942  6.09 48.675 48.57966 48.48451 0.44298778 0.5665511 0.9629539 0.8822506 1.2016609
G28 42.66 34.14 19.971871  8.52 38.400 38.16297 37.92741 0.75136630 0.3496347 0.7204744 0.8002813 1.0900154
G29 60.81 29.75 51.077125 31.06 45.280 42.53349 39.95357 1.92158419 0.4343023 0.6278299 0.4892287 0.6663493
G30 88.35 50.05 43.350311 38.30 69.200 66.49750 63.90054 1.63089195 1.0615507 1.0562315 0.5664969 0.7715916
G31 55.20 47.03 14.800725  8.17 51.115 50.95151 50.78854 0.55682144 0.6232240 0.9924989 0.8519928 1.1604485
G32 68.46 53.20 22.290389 15.26 60.830 60.34958 59.87296 0.83859179 0.8743366 1.1227076 0.7770961 1.0584363
G33 56.51 45.59 19.324013 10.92 51.050 50.75718 50.46603 0.72699312 0.6184791 0.9621098 0.8067599 1.0988395
G34 72.70 26.28 63.851444 46.42 49.490 43.70991 38.60489 2.40216975 0.4586590 0.5546007 0.3614856 0.4923579
G35 61.96 44.84 27.630730 17.12 53.400 52.70945 52.02784 1.03950198 0.6669713 0.9462821 0.7236927 0.9856987
G36 55.70 43.32 22.226212 12.38 49.510 49.12152 48.73609 0.83617739 0.5792603 0.9142048 0.7777379 1.0593104
G37 57.75 43.01 25.523810 14.74 50.380 49.83801 49.30186 0.96023706 0.5962818 0.9076627 0.7447619 1.0143958
G38 72.31 35.63 50.726041 36.68 53.970 50.75830 47.73773 1.90837595 0.6185065 0.7519187 0.4927396 0.6711312
G39 62.03 41.56 33.000161 20.47 51.795 50.77368 49.77250 1.24150659 0.6188814 0.8770626 0.6699984 0.9125649
G40 69.91 53.08 24.073809 16.83 61.495 60.91652 60.34349 0.90568627 0.8908413 1.1201752 0.7592619 1.0341454
G41 58.43 47.98 17.884648 10.45 53.205 52.94782 52.69188 0.67284243 0.6730173 1.0125472 0.8211535 1.1184443
G42 55.98 48.90 12.647374  7.08 52.440 52.32038 52.20103 0.47580974 0.6571611 1.0319625 0.8735263 1.1897780
G43 77.42 55.97 27.706019 21.45 66.695 65.82703 64.97035 1.04233447 1.0402521 1.1811644 0.7229398 0.9846732
G44 67.42 54.15 19.682587 13.27 60.785 60.42179 60.06076 0.74048309 0.8764302 1.1427560 0.8031741 1.0939556
G45 77.62 61.61 20.626127 16.01 69.615 69.15322 68.69451 0.77598024 1.1480346 1.3001883 0.7937387 1.0811042
G46 75.23 71.12  5.463246  4.11 73.175 73.14614 73.11729 0.20553403 1.2844373 1.5008828 0.9453675 1.2876288
G47 79.13 77.13  2.527486  2.00 78.130 78.12360 78.11720 0.09508714 1.4651922 1.6277150 0.9747251 1.3276150
G48 76.53 59.77 21.899909 16.76 68.150 67.63282 67.11956 0.82390145 1.0981081 1.2613578 0.7810009 1.0637548
G49 77.80 55.71 28.393316 22.09 66.755 65.83493 64.92754 1.06819143 1.0405019 1.1756775 0.7160668 0.9753120
G50 83.28 65.80 20.989433 17.48 74.540 74.02583 73.51521 0.78964826 1.3155178 1.3886121 0.7901057 1.0761558
G51 61.66 40.22 34.771327 21.44 50.940 49.79925 48.68404 1.30814001 0.5953546 0.8487839 0.6522867 0.8884409
G52 58.52 45.56 22.146275 12.96 52.040 51.63498 51.23311 0.83317006 0.6400563 0.9614767 0.7785373 1.0603992
G53 69.44 54.03 22.191820 15.41 61.735 61.25229 60.77336 0.83488353 0.9006889 1.1402236 0.7780818 1.0597788
G54 66.32 55.73 15.968034 10.59 61.025 60.79485 60.56556 0.60073704 0.8872861 1.1760996 0.8403197 1.1445493
G55 51.65 50.52  2.187803  1.13 51.085 51.08188 51.07875 0.08230782 0.6264174 1.0661502 0.9781220 1.3322416
G56 60.55 35.60 41.205615 24.95 48.075 46.42822 44.83786 1.55020585 0.5174808 0.7512856 0.5879438 0.8008033
G57 64.12 46.85 26.933874 17.27 55.485 54.80896 54.14116 1.01328542 0.7211626 0.9887002 0.7306613 0.9951901
G58 55.12 50.31  8.726415  4.81 52.715 52.66011 52.60528 0.32829845 0.6657231 1.0617184 0.9127358 1.2431831
G59 85.98 41.22 52.058618 44.76 63.600 59.53231 55.72477 1.95850915 0.8508158 0.8698874 0.4794138 0.6529810
G60 55.06 36.03 34.562296 19.03 45.545 44.54000 43.55718 1.30027601 0.4762452 0.7603601 0.6543770 0.8912880
G61 81.73 56.26 31.163587 25.47 68.995 67.80951 66.64439 1.17241243 1.1038533 1.1872844 0.6883641 0.9375797
G62 61.58 52.85 14.176681  8.73 57.215 57.04825 56.88199 0.53334414 0.7812945 1.1153214 0.8582332 1.1689483
G63 63.23 49.69 21.413886 13.54 56.460 56.05264 55.64822 0.80561668 0.7542621 1.0486343 0.7858611 1.0703746
G64 59.77 56.07  6.190397  3.70 57.920 57.89045 57.86091 0.23289032 0.8045331 1.1832748 0.9380960 1.2777247
G65 73.23 54.83 25.126314 18.40 64.030 63.36561 62.70812 0.94528280 0.9639120 1.1571064 0.7487369 1.0198098
G66 67.80 43.99 35.117994 23.81 55.895 54.61247 53.35937 1.32118207 0.7160012 0.9283441 0.6488201 0.8837191
G67 66.59 49.13 26.220153 17.46 57.860 57.19761 56.54281 0.98643436 0.7853910 1.0368163 0.7377985 1.0049113
G68 74.55 51.53 30.878605 23.02 63.040 61.98033 60.93848 1.16169104 0.9222272 1.0874647 0.6912140 0.9414613
G69 58.01 56.35  2.861576  1.66 57.180 57.17398 57.16795 0.10765599 0.7847420 1.1891837 0.9713842 1.3230646
G70 57.23 30.73 46.304386 26.50 43.980 41.93659 39.98813 1.74202786 0.4221982 0.6485114 0.5369561 0.7313559
G71 52.07 49.68  4.589975  2.39 50.875 50.86096 50.84693 0.17268050 0.6210110 1.0484232 0.9541002 1.2995231
G72 46.97 41.11 12.476049  5.86 44.040 43.94242 43.84507 0.46936427 0.4635517 0.8675660 0.8752395 1.1921116
G73 62.65 39.03 37.701516 23.62 50.840 49.44926 48.09657 1.41837735 0.5870157 0.8236707 0.6229848 0.8485305
G74 54.65 48.93 10.466606  5.72 51.790 51.71097 51.63206 0.39376656 0.6419416 1.0325956 0.8953339 1.2194810
G75 51.69 36.43 29.522151 15.26 44.060 43.39432 42.73869 1.11065959 0.4520597 0.7688015 0.7047785 0.9599368
G76 57.99 31.59 45.525091 26.40 44.790 42.80075 40.89985 1.71270982 0.4397773 0.6666604 0.5447491 0.7419703
G77 54.36 40.02 26.379691 14.34 47.190 46.64212 46.10060 0.99243637 0.5222599 0.8445631 0.7362031 1.0027383
G78 42.77 25.43 40.542436 17.34 34.100 32.97940 31.89563 1.52525624 0.2611053 0.5366627 0.5945756 0.8098360
G79 53.03 32.72 38.299076 20.31 42.875 41.65503 40.46977 1.44085827 0.4165480 0.6905074 0.6170092 0.8403915
G80 50.24 44.14 12.141720  6.10 47.190 47.09133 46.99287 0.45678641 0.5323682 0.9315097 0.8785828 1.1966653
G81 37.65 31.13 17.317397  6.52 34.390 34.23514 34.08097 0.65150175 0.2813677 0.6569528 0.8268260 1.1261704
G82 53.15 39.33 26.001881 13.82 46.240 45.72078 45.20739 0.97822271 0.5018308 0.8300017 0.7399812 1.0078843
G83 75.95 57.50 24.292298 18.45 66.725 66.08423 65.44961 0.91390607 1.0483969 1.2134528 0.7570770 1.0311695
G84 62.28 50.11 19.540784 12.17 56.195 55.86458 55.53609 0.73514828 0.7492092 1.0574977 0.8045922 1.0958870
G85 70.50 40.43 42.652482 30.07 55.465 53.38834 51.38943 1.60463877 0.6842629 0.8532156 0.5734752 0.7810964
G86 61.00 53.15 12.868852  7.85 57.075 56.93988 56.80508 0.48414203 0.7783290 1.1216525 0.8713115 1.1867614
G87 54.81 35.77 34.738186 19.04 45.290 44.27814 43.28889 1.30689324 0.4706617 0.7548732 0.6526181 0.8888923
G88 99.08 28.87 70.861930 70.21 63.975 53.48308 44.71183 2.66591282 0.6866934 0.6092588 0.2913807 0.3968723
G89 56.64 50.93 10.081215  5.71 53.785 53.70917 53.63345 0.37926768 0.6925116 1.0748026 0.8991879 1.2247302
G90 66.32 53.03 20.039204 13.29 59.675 59.30388 58.93506 0.75389946 0.8442990 1.1191200 0.7996080 1.0890983


> results$ranks
    Yp Ys TOL MP GMP HM SSI STI YI YSI RSI  SR        AR      Std.
G1  36 25  31 30  29 27  28  29 25  28  28 316 28.727273  3.036146
G2   6  3  28  3   3  3  18   3  3  18  18 106  9.636364  9.080449
G3   2  1  38  1   1  1  21   1  1  21  21 109  9.909091 13.026546
G4  23 78  86 46  55 67  87  55 78  87  87 749 68.090909 21.106656
G5  39 21  21 32  31 29  19  31 21  19  19 282 25.636364  6.960930
G6  21 39  75 23  24 26  66  24 39  66  66 469 42.636364 21.299168
G7  38 41  41 40  39 40  44  39 41  44  44 451 41.000000  2.144761
G8   9 10  80  8   8  8  62   8 10  62  62 327 29.727273 29.577325
G9   7  8  78  7   7  7  60   7  8  60  60 309 28.090909 29.286360
G10 22 15  58 17  16 15  47  16 15  47  47 315 28.636364 17.118836
G11 87 88  44 88  88 88  70  88 88  70  70 869 79.000000 14.205633
G12 53 56  50 53  53 55  57  53 56  57  57 600 54.545455  2.296242
G13 71 52  23 64  61 58  25  61 52  25  25 517 47.000000 18.590320
G14 50 71  72 68  69 69  76  69 71  76  76 767 69.727273  7.212363
G15 62 60  39 65  64 60  48  64 60  48  48 618 56.181818  8.795660
G16 55 22   8 38  37 35   8  37 22   8   8 278 25.272727 16.217835
G17 74 58  27 69  68 65  34  68 58  34  34 589 53.545455 17.597520
G18 42 11   9 29  27 22   7  27 11   7   7 199 18.090909 11.903399
G19 44 40  32 43  41 41  35  41 40  35  35 427 38.818182  3.894051
G20  4  4  42  2   2  2  24   2  4  24  24 134 12.181818 13.869522
G21 13 45  82 21  20 25  77  20 45  77  77 502 45.636364 27.724620
G22 79 77  49 83  80 79  64  80 77  64  64 796 72.363636 10.566671
G23 86 61   5 82  77 74   9  77 61   9   9 550 50.000000 34.152599
G24 75 80  64 84  83 80  72  83 80  72  72 845 76.818182  6.289963
G25  3 62  89 16  19 31  88  19 62  88  88 565 51.363636 34.305314
G26 83 82  61 86  86 85  73  86 82  73  73 870 79.090909  8.055489
G27 80 49  14 70  67 63  13  67 49  13  13 498 45.272727 26.844332
G28 89 79  20 87  87 87  32  87 79  32  32 711 64.636364 28.626116
G29 51 86  83 77  82 84  85  82 86  85  85 886 80.545455 10.132755
G30  5 36  85 10  12 16  81  12 36  81  81 455 41.363636 33.687602
G31 67 47  19 57  56 54  22  56 47  22  22 469 42.636364 17.777923
G32 30 26  45 27  26 24  43  26 26  43  43 359 32.636364  8.743829
G33 64 50  26 59  60 56  29  60 50  29  29 512 46.545455 15.102077
G34 25 89  88 67  78 86  89  78 89  89  89 867 78.818182 19.213632
G35 46 53  53 49  48 48  55  48 53  55  55 563 51.181818  3.400535
G36 66 57  30 66  66 61  42  66 57  42  42 595 54.090909 12.848771
G37 60 59  43 63  62 59  50  62 59  50  50 617 56.090909  6.640099
G38 26 75  84 47  59 66  84  59 75  84  84 743 67.545455 18.683488
G39 45 63  66 55  58 57  65  58 63  65  65 660 60.000000  6.292853
G40 28 28  52 25  22 21  45  22 28  45  45 361 32.818182 11.478834
G41 57 46  24 50  47 45  27  47 46  27  27 443 40.272727 11.602508
G42 65 44  17 52  50 47  16  50 44  16  16 417 37.909091 18.052449
G43 16 17  68 15  15 13  56  15 17  56  56 344 31.272727 22.253498
G44 32 23  34 28  25 23  31  25 23  31  31 306 27.818182  4.142902
G45 15  7  48  9   9  9  36   9  7  36  36 221 20.090909 15.488412
G46 19  5   7  6   6  6   5   6  5   5   5  75  6.818182  4.094342
G47 12  2   3  4   4  4   2   4  2   2   2  41  3.727273  2.901410
G48 17  9  50 12  11 10  39  11  9  39  39 246 22.363636 15.806788
G49 14 19  69 13  14 14  58  14 19  58  58 350 31.818182 23.219897
G50 10  6  57  5   5  5  37   5  6  37  37 210 19.090909 19.023431
G51 47 67  67 60  63 62  69  63 67  69  69 703 63.909091  6.425800
G52 56 51  33 54  52 51  40  52 51  40  40 520 47.272727  7.551038
G53 29 24  47 24  21 19  41  21 24  41  41 332 30.181818 10.215852
G54 34 18  25 26  23 20  23  23 18  23  23 256 23.272727  4.383855
G55 82 33   1 58  54 52   1  54 33   1   1 370 33.636364 28.914608
G56 52 76  74 71  72 72  79  72 76  79  79 802 72.909091  7.582276
G57 37 48  54 44  42 42  54  42 48  54  54 519 47.181818  6.177672
G58 68 34  10 51  49 46  10  49 34  10  10 371 33.727273 20.837903
G59  8 64  87 20  28 37  86  28 64  86  86 594 54.000000 30.453243
G60 69 73  62 75  74 76  67  74 73  67  67 777 70.636364  4.455844
G61 11 14  76 11  10 11  63  10 14  63  63 346 31.454545 27.847311
G62 48 30  22 35  35 33  20  35 30  20  20 328 29.818182  8.784283
G63 40 37  36 39  38 38  38  38 37  38  38 417 37.909091  1.044466
G64 54 15   6 33  32 30   6  32 15   6   6 235 21.363636 15.895111
G65 24 20  59 18  17 17  49  17 20  49  49 339 30.818182 16.744063
G66 31 55  73 42  43 44  71  43 55  71  71 599 54.454545 14.975738
G67 33 42  56 34  33 36  52  33 42  52  52 465 42.272727  9.155227
G68 20 31  70 22  18 18  61  18 31  61  61 411 37.363636 21.176745
G69 58 13   2 36  34 32   3  34 13   3   3 231 21.000000 18.745666
G70 61 85  79 81  84 83  83  84 85  83  83 891 81.000000  6.855655
G71 78 38   4 61  57 53   4  57 38   4   4 398 36.181818 27.683274
G72 85 65  13 80  76 75  15  76 65  15  15 580 52.727273 30.845067
G73 41 70  71 62  65 64  74  65 70  74  74 730 66.363636  9.458041
G74 72 43  12 56  51 49  12  51 43  12  12 413 37.545455 21.658087
G75 81 72  46 79  79 78  59  79 72  59  59 763 69.363636 11.707030
G76 59 83  77 78  81 81  82  81 83  82  82 869 79.000000  6.899275
G77 73 68  40 72  71 70  53  71 68  53  53 692 62.909091 11.121641
G78 88 90  55 90  90 90  78  90 90  78  78 917 83.363636 10.846868
G79 77 81  65 85  85 82  75  85 81  75  75 866 78.727273  6.100671
G80 84 54  15 72  70 68  14  70 54  14  14 529 48.090909 28.051576
G81 90 84  16 89  89 89  26  89 84  26  26 708 64.363636 32.573832
G82 76 69  37 74  73 71  51  73 69  51  51 695 63.181818 13.166763
G83 18 12  60 14  13 12  46  13 12  46  46 292 26.545455 18.672780
G84 43 35  29 41  40 39  30  40 35  30  30 392 35.636364  5.220589
G85 27 66  81 45  46 50  80  46 66  80  80 667 60.636364 18.747121
G86 49 27  18 37  36 34  17  36 27  17  17 315 28.636364 10.707686
G87 70 74  63 76  75 77  68  75 74  68  68 788 71.636364  4.455844
G88  1 87  90 19  45 73  90  45 87  90  90 717 65.181818 32.470966
G89 63 32  11 48  44 43  11  44 32  11  11 350 31.818182 18.410965
G90 34 29  35 31  30 28  33  30 29  33  33 345 31.363636  2.335497

Step 3: Plotting the results

1. Correlation matrixes

1. Install R library ggcorrplot
install.packages("ggcorrplot")
2. Load library ggcorrplot
library("ggcorrplot")
3. Plot the heatmap for correlation matrixes available in results$correlations variable (results$correlations$pearson and results$correlations$spearman)
ggcorrplot(results$correlations$pearson)

Pearson correlation heatmap

ggcorrplot(results$correlations$spearman)

Spearman correlation heatmap

2. Relative frequencies

1. Choose the indice which you want to make the histogram from
indice <- results$indices$Yp
2. Draw histogram of results relative frequency for chosen indice
h <- hist(indice, breaks = 10)
h$counts=h$counts/sum(h$counts)
plot(h,col="#f1a689")

Histogram for relative frequency

3. Principal component analysis

1. there are eigenvals (eigenvalues), eigenvecs (eigenvectors), loadings (factor loadings), contributions (contribution of Variables), scores (Factor Scores) and pca_obj (actual PCA object used for calculation of results) available for each correlation_based and covariance_based object inside pca object of result.

Example:

cor_based_pca <- results$pca$correlation_based
print(cor_based_pca) # cor_based_pca$eigenvals, cor_based_pca$eigenvecs, cor_based_pca$loadings, cor_based_pca$contributions, cor_based_pca$scores, cor_based_pca$pca_obj
cov_based_pca <- results$pca$covariance_based
print(cov_based_pca) # cov_based_pca$eigenvals, cov_based_pca$eigenvecs, cov_based_pca$loadings, cov_based_pca$contributions, cov_based_pca$scores, cov_based_pca$pca_obj
2. Draw pca biplot for results
biplot(results$pca$correlation_based$pca_obj, scale=0)

Correlation-based PCA Biplot

biplot(results$pca$covariance_based$pca_obj, scale=0)

Covariance-based PCA Biplot

You can’t perform that action at this time.