Genomic Selection Tutorial

Eli Gacasan

Overview


  1. What is genomic selection?
  2. History
  3. Tutorial

What is genomic selection?

The general process

André Eggen, The development and application of genomic selection as a new breeding paradigm, Animal Frontiers, Volume 2, Issue 1, January 2012, Pages 10–15, https://doi.org/10.2527/af.2011-0027

History

History

History

History

Implementation of genomic selection

Step 1. Getting Data CropGS-Hub

Getting Data

Loading in the data

files <- genio::read_plink(
  "data/GSTP011.bed/827millet"
)
# Phenotypic Data
phenotypes <- read.table("data/GSTP011.pheno", header = T)
# Genotypic Data
genotypes <- t(files$X)

Viewing the data (Genotypes)

(genotypes[,1:9])
        1_1952 1_16151 1_36102 1_37028 1_37519 1_37667 1_37980 1_43021 1_43024
Si_102       1       0       0       0       0       0       0       0       0
Si_105       0       0       0       0       0       0       0       0       0
Si_106      NA       0       0       0       0       0       0       0       0
Si_108       0       0       0       0       0       0       0       0       0
Si_109       0       0       0       0       0       0       0       0       0
Si_113       0       0       0       0       0       0       0       0       0
Si_127       0       0       0       0       0       0       0       0       0
Si_129       0       0       0       0       0       0       0       0       0
Si_132       0       0       0       0       0       0       0       2       2
Si_134       0       0       0       1       0       0       0       0       0
Si_137       0       0       0       0       0       0       0       0       0
Si_139       0       0       0       0       0       0       0       0       0
Si_141       0       0       0       0       0       0       0       0       0
Si_143       0       0       0       0       0       0       0       0       0
Si_150       0       0       0       2       0       0       0       0       0
Si_151       0       0       0       0       0       0       0       0       0
Si_153       0       0       0       0       0       0       0       0       0
Si_156       0       0       0       0       0       0       0       0       0
Si_157       0       0       0       0       0       0       0       0       0
Si_162       0       0       0       0       0       0       0      NA      NA
Si_163       0       0       0       1       0       0       0       0       0
Si_166       0       0       0       2       0       0       0       0       0
Si_180       0       0       0       0       0       0       0       0       0
Si_181       0       0       0       0       0       0       0       0       0
Si_182       0       0       0       0       0       0       2       0       0
Si_183       0       0       0       0       0       0       0       0       0
Si_186       0       0       0       0       0       0       0       0       0
Si_189       0       0       0       0       0       0       0       0       0
Si_195       0       0       0       0       0       0       0       0       0
Si_197       0       0       0       0       0       0       0       0       0
Si_198       0       0       0       0       0       0       0       0       0
Si_200       0       0       0       2       0       0       0       0       0
Si_203       0       0       0       0       0       0       0       0       0
Si_204       0       0       0       0       0       0       0       0       0
Si_205       0       0       0       0       0       0       0       0       0
Si_206       0       0       0       0       0       0       2       0       0
Si_207       0       0       0      NA       0       0       0       0       0
Si_208       0       0       0       0       0       0       0       0       0
Si_209       0       0       0       0       0       0       0       0       0
Si_210       0       0       0       2       0       0       0       0       0
Si_211       0       0       0       0       0       0       1       0       0
Si_212       0       1       0       0       0       0       0       0       0
Si_213       0       0       0       0       0       0       0       0       0
Si_214       0       0       0       0       0       0       0       0       0
Si_215       0       0       0       0       0       0       2       0       0
Si_217       0       0       0       0       0       0       0       0       0
Si_218       0       1       0       0       0       0       0       0       0
Si_219       0       0       0       0       0       0       0       0       0
Si_220       0       0       0       0       0       0       0       0       0
Si_223       0       1       0       0       0       0       0       0       0
Si_225       0       0       0       0       0       0       0       0       0
Si_226       0       0       0       0       0       0       0       0       0
Si_228       0       0       0       0       0       0       0       0       0
Si_231       0       0       0       0      NA      NA       0       0       0
Si_234       0       0       0       0       0       0       0       1       1
Si_236       0       1       0       0       0       0       0       0       0
Si_239       0       0       0       0       0       0       0      NA      NA
Si_240       0       0       0       0       0       0       0       0       0
Si_242       0       0       0       1       0       0       0       0       0
Si_245       0       0       0       0       0       0       0       0       0
Si_246       0       0       0       2       0       0       0       0       0
Si_248       0       0       0       0       0       0       0       0       0
Si_249       0       0       0       1       0       0       0       0       0
Si_251       0       0       0       0       0       0       0       0       0
Si_252       0       0       0       0       0       0       0       0       0
Si_253       0       0       0       0       0       0       0       0       0
Si_254       0       0       0       1       0       0       0       0       0
Si_255       0       0       0       0       0       0       0       0       0
Si_256       0       0       0       0       0       0       1       0       0
Si_257       0       0       0       0       0       0       0       0       0
Si_259       0       0       0       2       0       0       0       0       0
Si_260       0       0       0       0       0       0       0       0       0
Si_262       0       0       0       1       0       0       0       0       0
Si_263       0       0       0       0       0       0       0       0       0
Si_264       0       0       0       0       0       0       0       0       0
Si_269       0       0       0       0       0       0       0       0       0
YL_10        0       0       0       0       0       0       0       0       0
YL_100       0       1       0       0       0       0       0       0       0
YL_1004      0       0       0       0       0       0       0       0       0
YL_1005      0       0       0       0       0       0       0       0       0
YL_1009      0       0       0       0       0       0       0       0       0
YL_1013      0       0       0       0       0       0       0       0       0
YL_1016      0       0       0       0       0       0       0       0       0
YL_1018      0       0       0       0       0       0       0       0       0
YL_1019      0       0       0       0       0       0       0       0       0
YL_102       0       0       0       0       0       0       0       0       0
YL_1020      0       0       0       0       0       0       0       0       0
YL_1021      1       0       0       0       0       0       0       0       0
YL_1034      0       1       0       0       0       0       0       0       0
YL_1035      0       0       0       0       0       0       0       0       0
YL_1036      0       0       0       0       0       0       0       0       0
YL_1037      0       0       0       0       0       0       0       0       0
YL_1038      0       0       0       0       0       0       0       0       0
YL_104       0       1       0       0       0       0       0       0       0
YL_1044      0       0       0       0       0       0       0       0       0
YL_1045      0       0       0       0       0       0       0       2       2
YL_1046      0       1       0       0       0       0       0       0       0
YL_1047      0       0       0       0       0       0       0       0       0
YL_105       0       0       0       0       0       0       0       0       0
YL_1050      0       0       0       0       0       0       0       0       0
YL_1052      0       0       0       0       0       0       0       0       0
YL_1056      0       0       0       0       0       0       0       0       0
YL_1057      1       0       0       0       0       0       0       0       0
YL_106       0       0       0       0       0       0       0       0       0
YL_1062      1       0       0       0       0       0       0       0       0
YL_1070      0       0       0       0       0       0       0       0       0
YL_1071      0       0       0       0       0       0       0       0       0
YL_1072      0       1       0       0       0       0       0       0       0
YL_1073      0       0       0       0       0       0       0       0       0
YL_1075      0       0       0       0       0       0       0       0       0
YL_1076      0       1       0       0       0       0       0       0       0
YL_1077      0       0       0       0       0       0       0       0       0
YL_1078      0       0       0       0       0       0       0       0       0
YL_108       0       0       0       0       0       0       0       0       0
YL_1080      0       0       0       0       0       0       0       0       0
YL_1082      0       0       0       0      NA      NA       0       0       0
YL_1084      0       1       0       0       0       0       0       0       0
YL_1086      0       1       0       0       0       0       0       0       0
YL_1088      0       0       0       0       0       0       0       0       0
YL_1090      0       0       0      NA       0       0       0       0       0
YL_1096      0       0       0       0       0       0       0       0       0
YL_1098      0       0       0       0       0       0       0       0       0
YL_11        0       0       0       0       0       0       0       0       0
YL_1100      0       0       0       0       0       0       0       0       0
YL_1101      0       0       0       0       0       0       0       0       0
YL_1104      0       0       0       0       0       0       0       0       0
YL_1106      0       0       0       0       0       0       0       0       0
YL_1107      0       0       0       0       0       0       0       0       0
YL_1108      1       0       0       0       0       0       0       0       0
YL_1109      0       0       0       0       0       0       0       0       0
YL_111       0       2       0       0       0       0       0       0       0
YL_1112      0       0       0       0       0       0       0       0       0
YL_1114      0       0       0       0       0       0       0       0       0
YL_1115      0       0       0      NA       0       0       0       0       0
YL_1116      0       0       0       0       0       0       0       0       0
YL_1117      0       0       0       0       0       0       0       0       0
YL_1119      0       2       0       0       0       0       0       0       0
YL_1120      0       0       0       0       0       0       0       0       0
YL_1122      0       0       0       0       0       0       0       0       0
YL_1123      0       0       0       0       0       0       0       0       0
YL_1127      0       0       0       0       0       0       0       0       0
YL_1128      0       0       0       0       0       0       0       0       0
YL_1129      0       0       0       0       0       0       0       0       0
YL_1130      0       0       0       0       0       0       0       0       0
YL_1131      0       0       0       0       0       0       0       1       1
YL_1132      0       0       0       0       0       0       0       0       0
YL_1133      0       0       0       0       0       0       0       0       0
YL_1135      0       0       0       0       0       0       0       0       0
YL_1136      0       0       0       0       0       0       0       0       0
YL_1137      0       0       0       0       0       0       0       0       0
YL_1140      0       1       0       0       0       0       0       0       0
YL_1141      0       0       0       0       0       0       0       0       0
YL_1143      0       0       0       0       0       0       0      NA      NA
YL_1146      0       0       0       0       0       0       0       0       0
YL_1147      0       0       0       0       0       0       0       0       0
YL_1149      0       0       0       0       0       0       0       0       0
YL_1150      0       0       0       0       0       0       0       0       0
YL_1153      0       0       0       0       0       0       0       0       0
YL_1154      0       0       0       0       0       0       0       0       0
YL_1155      0       0       0       0       0       0       0       0       0
YL_1156      0       0       0       0       0       0       0       0       0
YL_1157      0       0       0       0       0       0       0       0       0
YL_116       0       0       0       0       0       0       0       0       0
YL_1160      0       0       0       0       0       0       0       0       0
YL_1163      0       0       0       0       0       0       0       0       0
YL_1164      0       0       0       0       0       0       0       0       0
YL_1166      0       0       0       0       0       0       0       0       0
YL_1167      0       0       0       1       0       0       0       0       0
YL_1169      0       0       0       0       0       0       0       0       0
YL_117       0       0       0       0       0       0       0       0       0
YL_1170      0       0       0       1       0       0       0       0       0
YL_1171      0       0       0       0       0       0       0       0       0
YL_1173      0       0       0       0       0       0       0       0       0
YL_1174      0       0       0       0       0       0       0       0       0
YL_1175      0       0       0       0       0       0       0       0       0
YL_1176      0       0       0       0       0       0       0       0       0
YL_1177      0       0       0       0       0       0       0       0       0
YL_1179      0       0       0       0       0       0       0       0       0
YL_1181      0       0       0       0       0       0       0       0       0
YL_1183      0       0       0       0       0       0       0       0       0
YL_1185      0       0       0       0       0       0       0       0       0
YL_1186      0       0       0       0       0       0       0       0       0
YL_1187      0       0       0       0       0       0       0       0       0
YL_1188      0       0       0       0       0       0       0       0       0
YL_1192      0       0       0       0       0       0       0       0       0
YL_1194      0       0       0       0       0       0       0       0       0
YL_1197      0       0       0       0       1       1       0       0       0
YL_12        0       0       0       0       0       0       0       0       0
YL_1200      0       1       0       0       0       0       0       0       0
YL_1201      0       0       0       0       0       0       0       0       0
YL_1203      0       0       0       0       0       0       0       0       0
YL_1204      0       0       0       0       0       0       0       0       0
YL_1205      0       0       0       0       0       0       0       0       0
YL_1206      0       0       0       0       0       0       0       0       0
YL_1207      0       0       0       0       0       0       0       0       0
YL_1208      0       0       0       0       0       0       0       0       0
YL_1209      0       0       0       0       0       0       0       0       0
YL_121       0       0       0       0       0       0       0       0       0
YL_1211      0       0       0       0       0       0       0       0       0
YL_1212      0       0       0       0       0       0       0      NA      NA
YL_1214      0       0       0       0       0       0       0       0       0
YL_1215      0       0       0       0       0       0       0       0       0
YL_1216      0       0       0       2       0       0       0       0       0
YL_1217      0       0       0       0       0       0       0       0       0
YL_1218      0       0       0       0       0       0       0       0       0
YL_1219      0       0       0       0       0       0       0       0       0
YL_1220      0       0       0       0       0       0       0       0       0
YL_1221      0       0       0       0       0       0       0       0       0
YL_1224      0       0       0       0       0       0       0       1       1
YL_1228      0       0       0       0       0       0       0       0       0
YL_1230      0       0       0       0       0       0       0       0       0
YL_1234      0       0       0       0       0       0       0       0       0
YL_1235      0       0       0       0       0       0       0       0       0
YL_1237      0       0       0       0       0       0       0       0       0
YL_1238      0       0       0       0       0       0       0       0       0
YL_1239      0       0       0       0       0       0       0       0       0
YL_124       0       0       0       0       0       0       0       0       0
YL_1240      0       0       0       0       0       0       0       0       0
YL_1241      0       0       0       0       0       0       0       0       0
YL_1243      0       0       0       0       0       0       0       0       0
YL_1245      0       0       0       0       0       0       0       0       0
YL_1246      0       0       0       0       0       0       0       0       0
YL_1247      0       0       0       0       0       0       0       0       0
YL_125       0       0       0       0       0       0       0       0       0
YL_1254      0       0       0       0       0       0       0       0       0
YL_1257      0       0       0       0       0       0       0       0       0
YL_1262      0       0       0       0       0       0       0       0       0
YL_1264      0       0       0       0       0       0       0       0       0
YL_1265      0       0       0       0       0       0       0       0       0
YL_127       0       0       0       0       0       0       0       0       0
YL_1275      0       0       0       0       0       0       0       0       0
YL_1276      0       0       0       0       0       0       0       0       0
YL_1277      0       0       0       0       0       0       0       0       0
YL_1278      0       0       0       0       0       0       0       0       0
YL_1279      0       0       0       0       0       0       0       0       0
YL_1280      0       0       0       0       0       0       0       0       0
YL_1281      0       0       0       0       1       1       0       0       0
YL_1282      0       0       0       0       0       0       0       0       0
YL_1283      0       0       0       0       0       0       0       0       0
YL_1284      0       0       0       0       0       0       0       0       0
YL_1287      0       0       0       0       0       0       0       0       0
YL_1288      0       0       0       0       0       0       0       0       0
YL_1289      0       0       0       0       0       0       0       0       0
YL_129       0      NA       0       0       0       0       0       0       0
YL_1292      1       0       0       0       0       0       0       0       0
YL_1293      0       0       0       0       0       0       0       0       0
YL_1294      0       0       0       0       0       0       0       0       0
YL_1295      0       0       0       0       0       0       0       0       0
YL_1296      0       1       0       0       0       0       0       0       0
YL_1298      0       0       0       0       0       0       0       0       0
YL_1299      0       0       0       0       0       0       0       0       0
YL_1300      0       0       0       0       0       0       0       0       0
YL_1301      1      NA       0       0       0       0       0       0       0
YL_1302      0       0       0       0       0       0       0       0       0
YL_1303      0       0       0       0       0       0       0       0       0
YL_1304      0       0       0       0       0       0       0       0       0
YL_1306      0       0       0       0       0       0       0       0       0
YL_1309      0       0       0       0       0       0       0       0       0
YL_131       0       0       0       0       0       0       0       0       0
YL_1311      0       0       0       0       0       0       0       0       0
YL_1312      0       0       0       0       0       0       0       0       0
YL_1314      0       0       0       0       0       0       0       0       0
YL_1315      0       0       0       0       0       0       0       0       0
YL_1316      0       0       0       0       0       0       0       0       0
YL_1318      0       0       0       0       0       0       0       0       0
YL_1319      0       0       0       0       0       0       0       0       0
YL_1321      0       0       0       0       0       0       0       0       0
YL_1323      0       1       0       0       0       0       0       0       0
YL_1325      0       0       0       0       0       0       0       0       0
YL_1326      0       2       0       0       0       0       0       0       0
YL_1327      0       0       0       0       0       0       0       0       0
YL_1328      0       0       0       0       0       0       0       0       0
YL_133       0       0       0       0       0       0       0       0       0
YL_1331      0       0       0       0       0       0       0       0       0
YL_1332      0       0       0       0       0       0       0       0       0
YL_1334      1       2       0       0       0       0       0       0       0
YL_1335      0       0       0       0       0       0       0       0       0
YL_1336      0       0       0       0       0       0       0       0       0
YL_1337      0       0       0       0       0       0       0       0       0
YL_1339      0       0       0       0       0       0       0       0       0
YL_134       0       0       0       0       0       0       0       0       0
YL_1340      0       0       0       0       0       0       0       0       0
YL_1343      0       1       0       0       0       0       0       0       0
YL_1344      0       0       0       0       0       0       0       0       0
YL_1345      0       0       0       0       0       0       0       0       0
YL_1346      0       0       0       0       0       0       0       0       0
YL_1347      0       0       0       0       0       0       0       0       0
YL_1348      0       1       0       0       0       0       0       0       0
YL_1349      0       0       0       0       0       0       0       0       0
YL_1352      0       1       0       0       0       0       0       0       0
YL_1353      0       0       0       0       0       0       0       0       0
YL_1355      0       2       0       0       0       0       0       0       0
YL_1356      0       0       0       0       0       0       0       0       0
YL_1358      0       1       0       0       0       0       0       0       0
YL_1359      0       0       0       0       0       0       0       0       0
YL_136       0       0       0       0       0       0       0       0       0
YL_1360      0       0       0       0       0       0       0       0       0
YL_1361      0       1       0       0       0       0       0       0       0
YL_1362      0       0       0       0       0       0       0       0       0
YL_1363      0       0       0       0       0       0       0       0       0
YL_1364      0       0       0       0       0       0       0       0       0
YL_1365      0       1       0       0       0       0       0       0       0
YL_1367      1       0       0       0       0       0       0       0       0
YL_1369      0       0       0       0       0       0       0       0       0
YL_1370      0       0       0       0       0       0       0       0       0
YL_1371      0       0       0       0       0       0       0       0       0
YL_1373      0       0       0       0       0       0       0       0       0
YL_1374      0       0       0       0       1       1       0       0       0
YL_1376      0       0       0       0       0       0       0       0       0
YL_1377      0       1       0       0       0       0       0       0       0
YL_1378      0       1       0       0       0       0       0       0       0
YL_1379      0       0       0       0       0       0       0       0       0
YL_138       0       0       0       0       0       0       2       0       0
YL_1381      0       0       0       0       0       0       0       0       0
YL_1382      0       0       0       0       0       0       0       0       0
YL_1383      0       1       0       0       0       0       0       0       0
YL_1384      0       0       0       0       0       0       0       0       0
YL_1386      0       0       0       0       0       0       0       0       0
YL_1387      0       1       0       0       0       0       0       0       0
YL_1388      0       1       0       0       0       0       0       0       0
YL_1389      0       0       0       0       0       0       0       0       0
YL_1390      0       0       0       0       0       0       0       0       0
YL_1391      0       0       0       0       0       0       0       0       0
YL_1392      0       0       0       0       0       0       0       0       0
YL_1393      0       1       0       0       0       0       0       0       0
YL_1394      0       0       0       0       0       0       0       0       0
YL_1397      0       0       0       0       0       0       0       0       0
YL_1398      0       0       0       0       0       0       0       0       0
YL_1399      0       0       0       0       0       0       0       0       0
YL_140       0       0       0       0       0       0       0       0       0
YL_1400      0       1       0       0       0       0       0       0       0
YL_1404      2       0       0       0       0       0       0       0       0
YL_1405      0       0       0       0       0       0       0       0       0
YL_1406      0       0       0       0       0       0       0       0       0
YL_1407      0       0       0       0       0       0       0       0       0
YL_1411      0       0       0       0       0       0       0       0       0
YL_1415      0       0       0       0       0       0       0       0       0
YL_1416      0       1       0       0       0       0       0       0       0
YL_1417      0       0       0       0       0       0       0       0       0
YL_1418      0       0       0       0       0       0       0       0       0
YL_1419      0       1       0       0       0       0       0       0       0
YL_1420      0       0       0       0       0       0       0       0       0
YL_1422      0       0       0       0       0       0       0       0       0
YL_1423      0       0       0       0       0       0       0       0       0
YL_1424      0       0       0       0       0       0       0       0       0
YL_1426      0       0       0       0       0       0       0       0       0
YL_1427      0       0       0       0       0       0       0       0       0
YL_1430      0       0       0       0       2       2       0       0       0
YL_1431      0       0       1       0       0       0       0       0       0
YL_1432      0       0       0       0       0       0       0       0       0
YL_1433      1       0       0       0       0       0       0       0       0
YL_1434      0       0       0       0       0       0       0       0       0
YL_1435      0       0       0       0       0       0       0       0       0
YL_1436      1       0       0       0       0       0       0       0       0
YL_1437      0       0       0       0       0       0       0       0       0
YL_1438      0       0       0       0       0       0       0       0       0
YL_144       0       0       0       0       0       0       0       0       0
YL_1440      0       0       1       0       0       0       0       0       0
YL_1442      0       0       0       0       0       0       0       0       0
YL_1444      0       0       0       0       0       0       0       0       0
YL_1445      0       0       0       0       2       2       0       0       0
YL_1446      0       0       0       0       0       0       0       0       0
YL_1447      0       0       0       0       0       0       0       0       0
YL_1449      0       0       0       0       0       0       0       0       0
YL_145       0       2       0       0       0       0       0       0       0
YL_1450      0       0       0       0       0       0       0       0       0
YL_1451      0       0       0       0       0       0       0       0       0
YL_1452      0       0       0       0       0       0       0       0       0
YL_1453      0       0       0       0       0       0       0       0       0
YL_1455      0       0       0       0       0       0       0       0       0
YL_1456      0       0       0       0       0       0       0       0       0
YL_1457      0       1       0       0       0       0       0       0       0
YL_1459      0       0       0       0       0       0       0       0       0
YL_1460      0       0       0       0       0       0       0       0       0
YL_1461      0       0       0       0       0       0       0       0       0
YL_1462      0       0       0       0       0       0       0       0       0
YL_1463      0       0       0       0       0       0       0       0       0
YL_1464      0       0       0       0       0       0       0       0       0
YL_1465      0       0       0       0       0       0       0       0       0
YL_1466      0       0       0       0       0       0       0       0       0
YL_1467      0       0       0       0       0       0       0       0       0
YL_1468      0       0       0       0       0       0       0       0       0
YL_1469      0       0       0       0       0       0       0       0       0
YL_147       0       0       0       0       0       0       0       0       0
YL_1470      0       0       0       0       0       0       0       0       0
YL_1471      0       0       0       0       0       0       0       0       0
YL_1473      0       0       0       0       0       0       0       0       0
YL_1474      0       0       0       0       0       0       0       0       0
YL_1475      0       0       0       0       0       0       0       0       0
YL_1476      0       0       0       0       0       0       0       0       0
YL_1477      0       0       0       0       0       0       0       0       0
YL_1478      0       0       0       0       0       0       0       0       0
YL_1479      0       0       0       0       0       0       0       0       0
YL_1480      0       0       0       0       0       0       0       0       0
YL_1483      0       0       0       0       0       0       0       0       0
YL_1486      0       0       0       0       0       0       0       0       0
YL_1489      0       0       0       0       0       0       0       0       0
YL_1490      2       0       0       0       0       0       0       0       0
YL_1491      0       0       0       0       0       0       0       0       0
YL_1492      0       1       0       0       0       0       0       0       0
YL_1493      0      NA       0       0       0       0       0       0       0
YL_1495      0       0       0       0       0       0       0       0       0
YL_15        0       0       0       0       0       0       0       0       0
YL_151       0       0       0       0       0       0       0       0       0
YL_152       0       0       0       0       0       0       0       0       0
YL_153       0       0       0       0       0       0       2       0       0
YL_156       0       0       0       0       0       0       0       0       0
YL_1575      0       0       0       0       0       0       0       0       0
YL_1578      0       0       0       0       0       0       0       0       0
YL_1580      0       0       0       0       0       0       0       0       0
YL_1581      0       0       0       0       0       0       0       0       0
YL_1582      0       0       0       0       0       0       0       0       0
YL_1584      1       0       0       0       0       0       0       0       0
YL_1587      0      NA       0       0       0       0       0       0       0
YL_1589      0       0       0       0       0       0       0       0       0
YL_16        0       0       0       0       0       0       0       0       0
YL_160       0       0       0       0       0       0       0       0       0
YL_1600      0       0       0       0       0       0       0       0       0
YL_1603      0       1       0       0       0       0       0       0       0
YL_1604      0       0       0       0       0       0       0       0       0
YL_1605      0       0       0       0       0       0       0       0       0
YL_1606      0       0       0       0       0       0       0       0       0
YL_1607      0       0       0       0       0       0       0       0       0
YL_161       0       0       0       0       0       0       0       0       0
YL_1612      0       0       0       0       0       0       0       0       0
YL_1615      0       0       0       0       0       0       0       0       0
YL_1616      0       0       0       0       0       0       0       0       0
YL_1618      0       0       0       0       0       0       0       0       0
YL_162       0       0       0       0       0       0       0       0       0
YL_1620      0       0       0       0       0       0       0       0       0
YL_1621      0       0       0       0       0       0       0       0       0
YL_1624      0       0       0       0       0       0       0       0       0
YL_1631      0       0       0       0       0       0       0       0       0
YL_1633      0       0       0       0       0       0       0       0       0
YL_1634      0       0       0       0      NA      NA       0       0       0
YL_164       0       0       0       0       0       0       0       0       0
YL_165       1       0       0       0       0       0       0       0       0
YL_166       0       0       0       0       0       0       0       0       0
YL_167       0       0       0       0       0       0       0       0       0
YL_168       0       1       0       0       0       0       0       0       0
YL_169       0       0       0       0       0       0       0       0       0
YL_17        0       0       0       0       0       0       0      NA      NA
YL_170       0       0       0       0       0       0       0       0       0
YL_172       0       1       0       0       0       0       0       0       0
YL_173       0       1       0       0       0       0       0       0       0
YL_175       0       0       0       0       0       0       0       0       0
YL_176       0       0       0       0       0       0       0       0       0
YL_178       0      NA       0       0       0       0       0       0       0
YL_18        0       0       0       0       0       0       0       2       2
YL_180       0      NA       0       0       0       0       0       0       0
YL_181       0       0       0       0       0       0       0       0       0
YL_185       0       0       0       0       0       0       0       0       0
YL_19        0       0       0       0       0       0       0       0       0
YL_193       0       0       0       0       0       0       0       0       0
YL_195       0       0       0       0       0       0       0       0       0
YL_196       0       0       0       0       1       1       0       0       0
YL_197       0       0       0       0       0       0       0       0       0
YL_199       0       0       0       0      NA      NA       0       0       0
YL_20        0       0       0       0       0       0       0       0       0
YL_202       0       0       0       0       0       0       0       0       0
YL_208       0       0       0       0       0       0       0       0       0
YL_21        0       1       0       0       0       0       0       0       0
YL_210       0       0       0       0       0       0       0      NA      NA
YL_211       0       0       0       0       0       0       0       0       0
YL_214       0       0       0       0       0       0       0       0       0
YL_215       0       0       0       0       0       0       0       0       0
YL_217       0       0       0       0       0       0       0       0       0
YL_219       0       0       0       0       0       0       0       0       0
YL_223       0       0       0       0       0       0       0       0       0
YL_225       0       0       0       0       0       0       0       0       0
YL_23        0       0       0       0       0       0       0       0       0
YL_230       0       0       0       0       0       0       0       0       0
YL_231       0       0       0       0       0       0       0       0       0
YL_234       0       1       0       0       0       0       0       0       0
YL_236       0       0       0       0       0       0       0       0       0
YL_238       0       0       0       0       0       0       0       0       0
YL_239       0       0       0       0       0       0       0       0       0
YL_24        0       0       0       0       0       0       0       0       0
YL_241       0       0       0       0       0       0       0       0       0
YL_242       0       1       0       0       0       0       0       0       0
YL_245       0       0       0       0       0       0       0       0       0
YL_247       0       0       0       0       0       0       0       0       0
YL_249       0       0       0       0       0       0       0       0       0
YL_25        0       0       0       0       0       0       0       0       0
YL_250       0       0       0       0       0       0       0       0       0
YL_251       0       0       0       0       0       0       0       0       0
YL_252       0       0       0       0       0       0       0       0       0
YL_253       0       0       0       0       0       0       0       0       0
YL_254       0       0       0       0       0       0       0       0       0
YL_255       0       0       0       0       0       0       0       0       0
YL_258       0       0       0       0       0       0       0       0       0
YL_259       0       0       0       0      NA      NA       0       0       0
YL_26        0       0       0       0       0       0       0       0       0
YL_260       0       0       0       0       0       0       0       0       0
YL_262       0       0       0       0       0       0       0       0       0
YL_263       0       0       0       0       0       0       0       0       0
YL_265       0       0       0       0       0       0       0       0       0
YL_266       0       0       0       0       0       0       0       0       0
YL_268       0       0       0       0       0       0       0       0       0
YL_273       0       0       0       0       0       0       2       0       0
YL_274       0       0       0       0       0       0       0       0       0
YL_275       0       0       0       0       0       0       0       0       0
YL_276       0       0       0       0       0       0       0       0       0
YL_28        0       0       0       0       0       0       0       0       0
YL_280       0       0       0       0       0       0       0       0       0
YL_281       0       0       0       0      NA      NA       0       0       0
YL_283       0       2       0       0       0       0       0       0       0
YL_287       0       0       0       0       0       0       1       0       0
YL_289       0       1       0       0       0       0       0       0       0
YL_29        0       0       0       0       0       0       0       0       0
YL_290       0       0       0       0       0       0       0       0       0
YL_291       0       0       0       0       0       0       0       0       0
YL_293       0       0       0       0       0       0       0       0       0
YL_294       0       0       0       0       0       0       0       0       0
YL_299       0       0       0       0       0       0       0       0       0
YL_3         0       0       0       0       0       0       0       0       0
YL_30        0       0       0       0       0       0       0       0       0
YL_305       0       0       0       0       0       0       0       0       0
YL_306       0       0       0       0       0       0       0       0       0
YL_307       0       0       0       0       0       0       0       0       0
YL_31        0       0       0       0       0       0       0       0       0
YL_310       0       0       0       0       0       0       1       0       0
YL_315       0       0       0       0       0       0       0       0       0
YL_316       0       0       0       0       0       0       0       0       0
YL_317       0       0       0       0       0       0       0       0       0
YL_318       0       0       0       0       0       0       0       0       0
YL_319       0       0       0       0       0       0       0       1       1
YL_32        0       0       0       0       0       0       0       0       0
YL_320       0       0       0       0       0       0       0       0       0
YL_321       0       0       0       0       0       0       0       0       0
YL_323       0       1       0       0       0       0       0       0       0
YL_324       0       0       0       0       0       0       0       0       0
YL_325       0       0       0       0       0       0       0       0       0
YL_33        0       0       0       0       0       0       0       1       1
YL_330       0       0       0       0       0       0       0       0       0
YL_34        0       0       0       0       0       0       0       0       0
YL_342       0       0       0       0       0       0       0       0       0
YL_345       0       0       0       0       0       0       0       0       0
YL_346       0       0       0       0       0       0       0       0       0
YL_347       0       0       0       0       0       0       0       0       0
YL_348       0       0       0       0       0       0       0       0       0
YL_349       0       0       0       0       0       0       0       0       0
YL_35        0       0       0       0       0       0       0       0       0
YL_350       0       0       0       0       0       0       0       0       0
YL_351       0       0       0       0       0       0       0       0       0
YL_352       0       1       0       0       0       0       0       0       0
YL_353       0       0       0       0       0       0       0       0       0
YL_354       0       0       0       0       0       0       0       0       0
YL_355       0       0       0       0       0       0       0       0       0
YL_356       0       0       0       0       0       0       0       0       0
YL_357       0       0       0       0       0       0       0       0       0
YL_358       0       0       0       0       0       0       0       0       0
YL_359       0       0       0       1       0       0       0       0       0
YL_36        0       0       0       0       0       0       0       0       0
YL_366       0       0       0       0       0       0       0       0       0
YL_367       0       0       0       0       0       0       0       0       0
YL_37        0       0       0       0       2       2       0       0       0
YL_370       0       0       0       0       0       0       0       0       0
YL_371       0       0       0       0       0       0       0       0       0
YL_373       0       0       0       0       0       0       0       0       0
YL_377       0       0       0       0       0       0       0       0       0
YL_380       0       0       0       0       0       0       0       0       0
YL_384       0       0       0       0       2       2       0       0       0
YL_385       0       0       0       2       0       0       0       0       0
YL_387       0       0       0       0       0       0       0       0       0
YL_39        1       0       0       0       0       0       0       0       0
YL_4         0       0       0       0       0       0       0       0       0
YL_403       0       0       0       0       2       2       0       0       0
YL_405       0       0       0      NA       0       0       0       0       0
YL_408       0       0       0       0       0       0       0       0       0
YL_411       0       0       0       0       0       0       0       0       0
YL_412       0       0       0       0       0       0       0       0       0
YL_413       0       0       0       0       0       0       0       0       0
YL_415       0       0       0       0       0       0       0       0       0
YL_416       0      NA       0       0       0       0       0       0       0
YL_417       0       0       0       0       0       0       0       0       0
YL_418       0       0       0       0       0       0       0       0       0
YL_419       0       0       0       1       0       0       0       0       0
YL_420       0       0       0       0       0       0       0       0       0
YL_422       0       0       0       0       0       0       0       0       0
YL_424       0       0       0       0       0       0       0       0       0
YL_426       0       0       0       0       0       0       0       0       0
YL_427       0       0       0       0       0       0       0       0       0
YL_428       0       0       0       0      NA      NA       0       0       0
YL_43        0       0       0       0       0       0       0       0       0
YL_430       0       0       0       0       0       0       0       0       0
YL_432       0       0       0       0       0       0       2       0       0
YL_435       0       0       0       0       0       0       0       0       0
YL_437       0       0       0       0       0       0       0       0       0
YL_443       0       0       0       0       0       0       0       0       0
YL_444       0      NA       0       0       0       0       0       0       0
YL_445       0       0       0       0       0       0       0       0       0
YL_446       0       0       0       0       0       0       0       0       0
YL_447       0       0       0       0       0       0       0       0       0
YL_448       0       0       0       0       0       0       0       0       0
YL_449       0       0       0       0       0       0       0       0       0
YL_450       0       1       0       0       0       0       0       0       0
YL_451       0       0       0       0       0       0       0       0       0
YL_452       0       0       0       0       0       0       0       0       0
YL_454       0       0       0       0       0       0       0       0       0
YL_455       0       0       0       0       0       0       0       0       0
YL_456       0       0       0       0       0       0       0       0       0
YL_459       0       0       0       0       1       1       0       0       0
YL_46        0       0       0       0       0       0       0       0       0
YL_460       0       0       0       0       0       0       0       0       0
YL_461       0       0       0       0       0       0       0       0       0
YL_463       0       0       0       0       0       0       0       0       0
YL_464       0       0       0       0       0       0       0       0       0
YL_467       0       0       0       0       0       0       0       0       0
YL_47        0       2       0       0       0       0       0       0       0
YL_474       0       0       0       0       0       0       0       0       0
YL_475       0       0       0       0       0       0       0       0       0
YL_481       0       0       0       0       0       0       0       0       0
YL_485       0       1       0       0       0       0       0       0       0
YL_487       0       0       0      NA       0       0       0       0       0
YL_488       0       0       0       0       0       0       0       0       0
YL_489       0       0       0       0       0       0       0       0       0
YL_494       0       0       0       0       0       0       0       0       0
YL_495       0       0       0       0       0       0       0       0       0
YL_497       0       0       0       0       0       0       0      NA      NA
YL_498       0       0       0       0       0       0       0       0       0
YL_500       0       0       0       0       0       0       0       1       1
YL_501       0       0       0       0      NA      NA       0       0       0
YL_505       0       0       0       2       0       0       0       0       0
YL_506       0       0       0       0       0       0       0       0       0
YL_507       0       0       0       2       0       0       0       0       0
YL_512       0       0       0       0       0       0       0       0       0
YL_520       0       0       0       0       0       0       0       0       0
YL_521       0       1       0       0       0       0       0       0       0
YL_523       0       0       0       2       0       0       0       0       0
YL_524       0       0       0       0      NA      NA       0       0       0
YL_530       0       0       0       0       0       0       0       0       0
YL_531       0       0       0       0       0       0       0       0       0
YL_538       0       0       0       0       0       0       0       0       0
YL_54        0       0       0       0       0       0       0       0       0
YL_540       0       0       0       0       0       0       0       0       0
YL_542       0       0       0       1       0       0       0       0       0
YL_545       0       0       0       0       0       0       0       0       0
YL_547       0       0       0       0       0       0       0       0       0
YL_548       0       0       0       0       0       0       0       0       0
YL_550       0       0       0       0       0       0       0       0       0
YL_551       0       0       0      NA       0       0       0       0       0
YL_552       0       0       0       0       0       0       0       0       0
YL_554       0       0       0       1       0       0       0       0       0
YL_558       0       0       0       0       0       0       0       0       0
YL_56        0       0       0       0       0       0       0       0       0
YL_560       0       0       0       0       0       0       0       0       0
YL_561       0       0       0       0       0       0       0       0       0
YL_563       0       0       0       0       0       0       0       0       0
YL_568       0       0       0       0       0       0       0       0       0
YL_569       0       0       0       0       0       0       0       0       0
YL_57        0       0       0       0       0       0       0       0       0
YL_570       0       0       0       0       0       0       0       0       0
YL_571       0       0       0       0       0       0       0       0       0
YL_572       0       0       0       0       0       0       0       0       0
YL_573       0       0       0       0       0       0       0       0       0
YL_575       0       0       0       0       0       0       0       0       0
YL_58        0       0       0       0       0       0       0       0       0
YL_580       0       0       0       0       0       0       0       0       0
YL_582       0       0       0       0       0       0       0       0       0
YL_587       0       0       0       0       0       0       0       0       0
YL_588       0       0       0       0       0       0       0       0       0
YL_59        0       0       0       0       0       0       0       0       0
YL_593       0       0       0       0       0       0       0       0       0
YL_597       0       0       0       0       0       0       0       0       0
YL_60        0       0       0       0       0       0       0       0       0
YL_601       0       0       0      NA       0       0       0       0       0
YL_604       0       0       0       0       0       0       0       0       0
YL_605       0       0       0       0       0       0       0       0       0
YL_606       0       0       0       0       0       0       0       0       0
YL_61        0       0       0       0       0       0       0       0       0
YL_616       0       0       0       0       0       0       0       0       0
YL_62        0       0       0       0       0       0       0       0       0
YL_625       0       0       0       0       0       0       0      NA      NA
YL_627       0       0       0       0       0       0       0       0       0
YL_628       0       0       0       0       0       0       0       0       0
YL_630       0       0       0       0       0       0       0       0       0
YL_633       0       0       0       0       0       0       0       0       0
YL_634       0       0       0       0       0       0       0       0       0
YL_639       0       0       0       0       0       0       0       0       0
YL_64        0       1       0       0       0       0       0       0       0
YL_640       0       0       0       0       0       0       0       0       0
YL_641       0       0       0       0       0       0       0       0       0
YL_642       0       0       0       0       0       0       0       0       0
YL_645       0       0       0       0       0       0       0       0       0
YL_650       0       0       0       0       0       0       0       0       0
YL_651       0       0       0       0       0       0       0      NA      NA
YL_653       0       0       0       0       0       0       0      NA      NA
YL_656       0       0       0       0       0       0       0       0       0
YL_657       0       0       0       0       0       0       0      NA      NA
YL_659       0       0       0       0       0       0       0       1       1
YL_66        0       0       0       0       0       0       0       0       0
YL_660       0       0       0       0       0       0       0       0       0
YL_664       0       0       0       0      NA      NA       0       0       0
YL_67        0       0       0       0       0       0       0       0       0
YL_670       0       0       0       1       0       0       0       0       0
YL_671       0       0       0       0       0       0       0       0       0
YL_673       0       0       0       0       0       0       0       0       0
YL_674       0       0       0       0       0       0       0       0       0
YL_678       0       0       0       0       0       0       0       0       0
YL_679       0       0       0       0       0       0       0       0       0
YL_68        0       0       0       0       0       0       0       0       0
YL_680       0       0       0       0       0       0       0       0       0
YL_682       0       0       0       0       0       0       0       0       0
YL_683       0       0       0       0       0       0       0       0       0
YL_684       0       0       0       0       0       0       0      NA      NA
YL_685       0       0       0       1       0       0       0       0       0
YL_686       0       0       0       0       0       0       0       1       1
YL_687       0       0       0       2       0       0       0       0       0
YL_688       0       0       0      NA       0       0       0       0       0
YL_69        0       0       0       0       0       0       0       0       0
YL_690       0       0       0       0       0       0       0       0       0
YL_691       0       0       0       0       0       0       0       0       0
YL_694       0       0       0       0       0       0       0       0       0
YL_699       0       0       0       0       0       0       0       0       0
YL_70        0       0       0       0       0       0       0       0       0
YL_700       0       0       0      NA       0       0       0       0       0
YL_701       0       0       0       2       0       0       0       0       0
YL_702       0       0       0       1       0       0       0       0       0
YL_703       0       0       0       1       0       0       0       1       1
YL_704       0       0       0       0       2       2       0       1       1
YL_706       0       0       0       0       0       0       0      NA      NA
YL_707       0       0       0       0       0       0       0       2       2
YL_709       0       0       0       0       0       0       0       0       0
YL_710       0       0       0       0       0       0       0       0       0
YL_711       0       0       0       0       0       0       0       0       0
YL_712       0       0       0       0       0       0       0       0       0
YL_713       0       0       0       0       0       0       0       2       2
YL_719       0       0       0       0       0       0       0       0       0
YL_72        0       0       0       0       0       0       0       0       0
YL_720       0       0       0       0       0       0       0       0       0
YL_732       0       1       0       0       0       0       0       0       0
YL_733       0       0       0       0       0       0       0       0       0
YL_734       0       0       0       0       0       0       0       0       0
YL_735       0       0       0       0       0       0       0       0       0
YL_737       0       0       0       0       0       0       0       0       0
YL_738       0       0       0       0       0       0       0       0       0
YL_739       0       0       0       0       0       0       0       0       0
YL_74        0       0       0       0       0       0       0       1       1
YL_740       0       0       0       0       0       0       0       0       0
YL_741       0       1       0       0       0       0       0       0       0
YL_743       0       0       0       0       0       0       0       0       0
YL_744       0       0       0       0       0       0       0       0       0
YL_746       0       0       0       0       0       0       0       0       0
YL_748       0       0       0       0       0       0       0       0       0
YL_749       0       0       0       0       0       0       0       0       0
YL_75        0       0       0       0       0       0       0       0       0
YL_753       0       0       0       0       0       0       0       0       0
YL_793       0       0       0       0       0       0       0      NA      NA
YL_80        0       0       0       0       0       0       0       0       0
YL_81        0       0       0       0       0       0       0       0       0
YL_813       0       0       0       0       0       0       0       0       0
YL_814       0       0       0      NA       0       0       0       0       0
YL_819       0       0       0       0       0       0       0       0       0
YL_82        0       0       0       0       0       0       0       0       0
YL_821       0       0       0       0       0       0       0      NA      NA
YL_823       0       0       0       0       0       0       0       0       0
YL_83        0       0       0       1       0       0       0       0       0
YL_836       0       0       0       0       0       0       0       0       0
YL_837       0       0       0       0       0       0       0       0       0
YL_838       0       0       0       0       0       0       0       0       0
YL_849       0       0       0       0       0       0       0       0       0
YL_85        0       0       0      NA       0       0       0       0       0
YL_86        0       0       0       0       0       0       0       0       0
YL_862       0       0       0       2       0       0       0       0       0
YL_864       0       0       0       0       0       0       0       0       0
YL_865       0       0       0       0      NA      NA       0       0       0
YL_866       0       0       2       0       0       0       0       0       0
YL_868       0       0       2       0       0       0       0       0       0
YL_87        0       0       0       0       0       0       0       0       0
YL_871       0       0       1       0       0       0       0       0       0
YL_874       0       0       2       0       0       0       0       0       0
YL_876       0       0       0       0      NA      NA       0       1       1
YL_877       0       0       0       0      NA      NA       0       0       0
YL_88        0       0       0       0       0       0       0       0       0
YL_886       0       0       0       0       0       0       0       0       0
YL_887       0       0       0       0       0       0       0       0       0
YL_888       0       0       0       0       0       0       0       0       0
YL_889       0       0       0       0       0       0       0       0       0
YL_89        0       0       0       0       0       0       0       0       0
YL_891       0       0       0       0       0       0       0       0       0
YL_892       0       0       0       0       0       0       0       0       0
YL_894       0       0       0       0       0       0       0       0       0
YL_895       0       0       2       0       0       0       0       0       0
YL_896       0       0       2       0       0       0       0       0       0
YL_897       0       0       2       0       0       0       0       0       0
YL_90        0       0       0       0       0       0       0       0       0
YL_903       0       0       0       0       0       0       0       0       0
YL_905       0       0       0       0       0       0       0       0       0
YL_906       0       0       0       0       0       0       1       0       0
YL_91        0       0       0      NA       0       0       0       0       0
YL_911       0       0       0       0       0       0       0       0       0
YL_912       0       0       0       0       0       0       0       0       0
YL_913       0       0       0       0       0       0       0       0       0
YL_914       0       0       0       0       0       0      NA       0       0
YL_916       0       0       0       0       0       0       0       0       0
YL_92        0       0       0       0       0       0       0       0       0
YL_923       0       0       0       0       0       0       0       0       0
YL_93        0       0       0       0       0       0       0       0       0
YL_931       0       0       0       0       0       0       1       0       0
YL_935       0       0       0       0       0       0       0       0       0
YL_936       0       0       0      NA       0       0       0       0       0
YL_94        0       0       0       0       0       0       0       0       0
YL_943       0       0       0       0       0       0       0       0       0
YL_945       0       0       0       0       0       0       0       0       0
YL_946       0       0       0       0       0       0       0       0       0
YL_947       0       0       0       0       0       0       0       0       0
YL_95        0       0       0       0       0       0       0       0       0
YL_953       0       0       0       0       0       0       0       0       0
YL_96        0       0       0       0       0       0       0       0       0
YL_965       0       0       2       0       0       0       0       0       0
YL_967       0       0       0       0       0       0       0       0       0
YL_968       0       0       0       0       0       0       0       0       0
YL_969       0       0       0       0       0       0       0       0       0
YL_97        0       0       0       0       0       0       0      NA      NA
YL_975       0       0       0       0       0       0       0       0       0
YL_977       0       0       0       0       0       0       0       0       0
YL_978       0       0       0       0       0       0       0       0       0
YL_982       0       0       0       0       0       0       0       0       0
YL_983       0       0       0       0       0       0       0       0       0
YL_986       0       0       0       0       0       0       0       0       0
YL_988       1       0       0       0       0       0       0       0       0
YL_989       0       0       0       0       0       0       0       0       0
YL_990       0       0       0       0       0       0       0       0       0
YL_991       0       0       0       0       0       0       0       0       0
YL_992       0       0       0       0       0       0       0       0       0
YL_995       0       0       0       0       0       0       0       0       0

LINE Top second leaf length Top second leaf width Main stem height Main stem width Panicle length of the main stem Panicle diameter of the main stem Fringe neck length Main stem panicle weight Per plant grain weight Hundred kernel weight Spikelet number of the main stem Grain number per spike
Si_102 37.77 3.03 115.8 6.07 24.57 33.4 29.77 28.81 23.34 0.32 90.33 140.67
Si_105 64.6 4.07 155.5 6.43 29.33 31.3 33.57 38.97 29.01 0.29 153.33 99.33
Si_106 34.37 3.43 93.87 5.43 20.83 33.43 24.87 24.49 20.17 0.32 111 93
Si_108 45.63 3.23 151.8 8.5 29.53 31.57 42.7 23.65 20.27 0.32 95 93.33
Si_109 43.33 3.53 125.53 6.67 27.27 33.4 32.97 30.93 26.39 0.33 131.33 133
Si_113 47.27 2.97 159.97 6.67 20.23 28.63 24.7 16.2 7.88 0.31 65 94

Splitting Data into testing and training dataset

### Creating Testing and Training Dataset by randomization ###
set.seed(123) 

# 
training_indices <- sample(1:827, size = 600, replace = FALSE)

# Training data
training.genotypes <- genotypes[training_indices, ]
training.phenotypes <- phenotypes$MSPD[training_indices]

# Testing data (select all rows NOT in training_indices)
testing_indices <- (1:827)[-training_indices] # Selects all indices *not* in training_indices

testing.genotypes <- genotypes[testing_indices, ]
testing.phenotypes <- phenotypes$MSPD[testing_indices]
### End Creating Testing and Training Dataset ###

# We pick MSPD (Main Stem Panicle Diameter) as the trait

The general process

André Eggen, The development and application of genomic selection as a new breeding paradigm, Animal Frontiers, Volume 2, Issue 1, January 2012, Pages 10–15, https://doi.org/10.2527/af.2011-0027

Step 2. Define the model

\[ y = X\beta + Zg +\epsilon, \] \[ g \sim N(0,G\sigma_g^2), \] \[ \epsilon \sim N(0,I\sigma_\epsilon^2) \]

Example: 2 Different Environments 2 Replications

\[ \small{\begin{pmatrix}y_1\\y_2\\y_3\\y_4\\y_5\\y_6 \end{pmatrix}}= \small{\begin{pmatrix}1 & 0 \\1 & 0 \\ 1 & 0 \\ 0 & 1 \\ 0 & 1 \\ 0 & 1 \end{pmatrix}} \begin{pmatrix} \beta_1 \\ \beta_2 \end{pmatrix} + \begin{pmatrix}1&0&0\\ 0&1&0\\ 0&0&1 \\ 1&0&0 \\0&1&0 \\0&0&1 \end{pmatrix} \begin{pmatrix}g_1 \\g_2 \\ g_3 \end{pmatrix} + \begin{pmatrix}\epsilon_1 \\ \epsilon_2 \\ \epsilon_3 \\ \epsilon_4 \\ \epsilon_5 \\ \epsilon_6 \end{pmatrix} \]

Example: 2 Different Environments 2 Replications

\[ \begin{pmatrix}y_1\\y_2\\y_3\\y_4\\y_5\\y_6\end{pmatrix}= \begin{pmatrix}\beta_1 \\ \beta_1 \\ \beta_1 \\ \beta_2 \\ \beta_2 \\ \beta_2 \end{pmatrix}+\begin{pmatrix}g_1 \\g_2 \\ g_3 \\g_1 \\ g_2 \\ g_3 \end{pmatrix} + \begin{pmatrix}\epsilon_1 \\ \epsilon_2 \\ \epsilon_3 \\ \epsilon_4 \\ \epsilon_5 \\ \epsilon_6 \end{pmatrix} \]

Example: 1 Environment

\[ \small{ \begin{pmatrix}y_1\\y_2\\y_3\\y_4\\y_5\\y_6 \end{pmatrix}= \begin{pmatrix}1 \\1 \\ 1 \\ 1 \\ 1 \\ 1 \end{pmatrix} \begin{pmatrix} \beta_1 \\ \end{pmatrix} + \begin{pmatrix}1&0&0&0&0&0 \\ 0&1&0&0&0&0\\ 0&0&1&0&0&0 \\ 0&0&0&1&0&0 \\0&0&0&0&1&0 \\0&0&0&0&0&1 \end{pmatrix} \begin{pmatrix}g_1 \\g_2 \\ g_3 \\g_4 \\ g_5 \\ g_6 \\ \end{pmatrix} + \begin{pmatrix}\epsilon_1 \\ \epsilon_2 \\ \epsilon_3 \\ \epsilon_4 \\ \epsilon_5 \\ \epsilon_6 \end{pmatrix}} \]

Example: 1 Environment

\[ \begin{pmatrix}y_1\\y_2\\y_3\\y_4\\y_5\\y_6\ \end{pmatrix}= \begin{pmatrix}\beta_1 \\ \beta_1 \\ \beta_1\\ \beta_1 \\ \beta_{1} \\ \beta_{1} \end{pmatrix}+\begin{pmatrix}g_1 \\g_2 \\ g_3 \\g_4 \\ g_5 \\ g_6 \end{pmatrix} + \begin{pmatrix}\epsilon_1 \\ \epsilon_2 \\ \epsilon_3 \\ \epsilon_4 \\ \epsilon_5 \\ \epsilon_6 \end{pmatrix} \]

Creating the genomic relationship matrix G

library(ASRgenomics)

### End Creating Genomic Relationship Matrix from Training Genotypes ###
genomic.relationship.matrix <- ASRgenomics::G.matrix(training.genotypes)
Initial data: 
    Number of Individuals: 600 
    Number of Markers: 161562 

Missing data check: 
    Total SNPs: 161562 
     0 SNPs dropped due to missing data threshold of 0.5 
    Total of: 161562  SNPs 

MAF check: 
    No SNPs with MAF below 0 

Heterozigosity data check: 
    No SNPs with heterozygosity, missing threshold of =  0 

Summary check: 
    Initial:  161562 SNPs 
    Final:  161562  SNPs ( 0  SNPs removed) 
 
Completed! Time = 102.27  seconds 

Fitting the model

library(lme4GS)
library(lme4)
data <- data.frame(y = training.phenotypes, G_ind = rownames(training.genotypes))

lme4.model <- lme4GS::lmerUvcov(
  formula = y ~ (1|G_ind),
  data = data,
  Uvcov = list(G_ind = list(K=genomic.relationship.matrix$G))
)

Summary of the model

summary(lme4.model)
Linear mixed model fit by REML ['lmerUvcov']
Formula: y ~ (1 | G_ind)
   Data: data

REML criterion at convergence: 4201.7

Scaled residuals: 
     Min       1Q   Median       3Q      Max 
-1.68395 -0.42267  0.00754  0.40694  2.17887 

Random effects:
 Groups   Name        Variance Std.Dev.
 G_ind    (Intercept) 36.25    6.021   
 Residual             22.79    4.774   
Number of obs: 600, groups:  G_ind, 600

Fixed effects:
            Estimate Std. Error t value
(Intercept)  19.6438     0.2277   86.29

\[ y = 1\beta+g+\epsilon,\text{ } g \sim N(0,G\sigma_g^2), \epsilon \sim N(0,I\sigma_\epsilon^2) \\ \hat{\beta}=20.6037, \hat{\sigma}^2_g=37.48,\hat{\sigma}^2_\epsilon=23.28 \]

The general process

Using the testing set

# Calculating Genomic Relationships for the entire dataset (between testing individuals and training individuals) 
full.genomic.relationship.matrix <- ASRgenomics::G.matrix(genotypes)
Initial data: 
    Number of Individuals: 827 
    Number of Markers: 161562 

Missing data check: 
    Total SNPs: 161562 
     0 SNPs dropped due to missing data threshold of 0.5 
    Total of: 161562  SNPs 

MAF check: 
    No SNPs with MAF below 0 

Heterozigosity data check: 
    No SNPs with heterozygosity, missing threshold of =  0 

Summary check: 
    Initial:  161562 SNPs 
    Final:  161562  SNPs ( 0  SNPs removed) 
 
Completed! Time = 148.56  seconds 

Using the testing set

# Calculate random effects (genomic estimated breeding values) for the testing data
GEBVs <- lme4GS::ranefUvcovNew(lme4.model, Uvcov=list(G_ind=list(K=full.genomic.relationship.matrix$G)))

\[ y = 1\beta+g+\epsilon\\ g \sim N(0,G\sigma_g^2)\\ \epsilon \sim N(0,I\sigma_\epsilon^2) \]

Genomic Estimated Breeding Values

GEBVs$G_ind
                [,1]
Si_102    3.63721413
Si_106    3.80270060
Si_108    1.20609519
Si_127   -1.35969562
Si_132   -1.25698249
Si_139    5.75076470
Si_150    2.47713127
Si_153   -0.21276646
Si_156    4.38594092
Si_166    4.78286876
Si_182    4.71500115
Si_186    3.80326294
Si_189   -0.86524323
Si_200   11.09486721
Si_212    0.63524725
Si_213    6.40476915
Si_214    1.27558909
Si_223    9.16416755
Si_228    0.53999192
Si_236   10.82119041
Si_240    2.73474888
Si_245   -1.11774780
Si_248    1.60105634
Si_249    7.25275246
Si_253   -0.11201061
Si_257    7.86791331
YL_10    -9.93715945
YL_1013  -3.52587310
YL_102   -5.10055678
YL_1037  -3.09649381
YL_1038  -2.69194562
YL_1046   2.04425710
YL_105  -12.88642059
YL_1052   2.77484466
YL_1056   1.53824312
YL_1071   7.91115393
YL_1073   5.96198114
YL_11   -10.34467925
YL_1104   5.35423790
YL_1123   3.14904354
YL_1128  -0.23842924
YL_1130   0.54769526
YL_1131   4.50665431
YL_1132   4.72681966
YL_1133   5.92404066
YL_1136   7.02008220
YL_1137   3.78298538
YL_1146   0.99826979
YL_1150   5.78295883
YL_1171  -0.87551823
YL_1173   7.03041881
YL_1176   8.42727805
YL_1186   5.18692417
YL_1187  -0.17695821
YL_1204   5.73769581
YL_1206   0.62912844
YL_121   -5.80488994
YL_1221   1.79704433
YL_1235   1.81244711
YL_1237  -3.04814823
YL_1238   3.64821715
YL_1239   5.82398206
YL_127  -13.17188387
YL_1277   7.53992800
YL_1292   7.46667427
YL_1294   5.49956980
YL_1296   1.28628769
YL_1301   2.52259630
YL_1302   7.31913945
YL_1304   3.47338039
YL_1306   4.07558327
YL_1319   4.50865834
YL_1325   2.42824815
YL_1331  14.15175401
YL_1332   2.64645002
YL_1343  11.36994929
YL_1345   3.86617498
YL_1356  10.80424545
YL_136   -8.55085104
YL_1363   4.09294138
YL_1373  -1.13975507
YL_138  -10.60547430
YL_1381  -3.58224598
YL_1386   8.99289068
YL_1388   1.17382516
YL_1389   2.81181635
YL_1392   8.16005177
YL_1393  -0.12544605
YL_1397   9.71916002
YL_1398   7.95331780
YL_1404   0.06870488
YL_1407   5.38027183
YL_1419   7.15253107
YL_1420  10.35789924
YL_1442  -7.04739297
YL_1444   2.34566111
YL_1450   3.87447089
YL_1452   5.27918149
YL_1455   7.42698938
YL_1457  -3.89903509
YL_1466   7.14042263
YL_1469   2.27420741
YL_1470  10.79409793
YL_1473  -1.04540017
YL_1480   2.88416482
YL_152   -4.20232232
YL_153  -12.12750351
YL_156    3.91303796
YL_1575  -2.43027442
YL_1580   1.37968678
YL_1581   4.12568099
YL_1587   8.04943895
YL_16    -7.02157203
YL_1603   0.57360341
YL_1607  -8.86476605
YL_1612   2.36105967
YL_1634   2.24671715
YL_166  -13.26017604
YL_167   -3.50491159
YL_168  -14.23397799
YL_172  -12.05227752
YL_175   -8.29825059
YL_18     9.52703984
YL_19   -18.58577568
YL_202   -6.10456688
YL_21   -15.13787032
YL_217   -7.26605875
YL_223    0.66310595
YL_23    -7.85504558
YL_234  -10.37714803
YL_238   -6.11817681
YL_24    -1.81854708
YL_245   -9.86653723
YL_253  -14.65366590
YL_259    1.96984360
YL_26   -11.85300063
YL_275  -15.65466006
YL_28   -10.15316684
YL_283  -14.45182554
YL_290  -11.09618003
YL_294   -8.74356982
YL_30   -12.27356959
YL_307    1.64940362
YL_321    1.91379208
YL_324   -5.74334861
YL_325   -3.10126640
YL_330    1.67683297
YL_347   -3.50931761
YL_349   -1.04153184
YL_352    1.89740491
YL_355    2.83303818
YL_358   -1.14576547
YL_367   -9.71553781
YL_380   -0.99668506
YL_384    3.79287470
YL_39    -5.42037067
YL_405    2.11402825
YL_408  -11.76954185
YL_415    2.64411892
YL_417    5.85069502
YL_427    3.94421210
YL_428    9.40408945
YL_448    0.37563446
YL_449   -2.33387719
YL_452    0.40154272
YL_46    -7.39428653
YL_463    1.33724819
YL_464  -10.41716360
YL_467   -2.34883602
YL_474    6.65985007
YL_487    1.29174765
YL_501    3.32218584
YL_505    7.38045172
YL_506    1.31704446
YL_521    6.22948131
YL_524   -1.68286183
YL_530    7.18288405
YL_538    3.98340603
YL_545    5.67473287
YL_547   -2.27874299
YL_550   -0.58831889
YL_551    0.37510475
YL_554    2.71473409
YL_572   -2.06160537
YL_573   -0.29030787
YL_575    0.68718243
YL_582    4.75765625
YL_587   -0.83009656
YL_605    5.31196773
YL_606    2.67365220
YL_616    2.90182106
YL_642    2.47972724
YL_651   -0.81169106
YL_664    5.95484146
YL_67    -4.30604249
YL_673    4.17090233
YL_68    -2.49441737
YL_683    7.70477662
YL_688    5.42055235
YL_70   -15.44205979
YL_703    6.48497783
YL_709    3.59155785
YL_713    6.04072267
YL_719    5.76981860
YL_732    3.66518687
YL_737    7.09949527
YL_74     3.85212114
YL_748   -5.01416846
YL_749    2.90942350
YL_81    -7.45086233
YL_821    1.56121910
YL_83    -6.23194272
YL_87   -11.21262876
YL_876    2.89741059
YL_887   -2.31211885
YL_891   -8.48651185
YL_895   -0.10059342
YL_896   -9.02267074
YL_90    -5.27228602
YL_905   -1.87462487
YL_914   -6.52855392
YL_916   -3.74814938
YL_947   -6.50863270
YL_97    -4.19788962
YL_977    3.86040810
YL_990    4.37994040
YL_991   -3.91031741

Calculating expected phenotypic value

# Calculating the expected phenotypic value
expected.phenotypes <- rep(20.6037, 227) + GEBVs$G_ind

\[ \hat{y}=\hat{\beta}+\hat{g} \]

# Calculating the correlation between the expected phenotypes and observed phenotypes
cor(testing.phenotypes, expected.phenotypes)
          [,1]
[1,] 0.6248235

Observed vs Predicted phenotypes of testing dataset

Histogram of the observed phenotypes

The general process

Summary

  1. Reference Population
  2. Model
  3. From the model and reference population you can train the model, predict breeding values, get a measure of predictive accuracy
  4. You can use the model to get breeding values for new candidates and select candidates based on predicted breeding values.

References

Symposium review: How to implement genomic selection

Linkage disequilibrium — understanding the evolutionary past and mapping the medical future

Genomic selection: A paradigm shift in animal breeding

Genomic selection M.E. Goddard & B.J. Hayes

Genomic BLUP Decoded: A Look into the Black Box of Genomic Prediction

Course Notes ‘QTL Mapping, MAS, and Genomic Selection’ (Hayes, 2007)

Genomic selection in plant breeding: from theory to practice

Genome-wide association and genomic selection in animal breeding (Ben Hayes and Mike Goddard)

Will genomic selection be a practical method for plant breeding?

Progress and perspectives on genomic selection models for crop breeding

Genomic selection in plant breeding: Key factors shaping two decades of progress

The development and application of genomic selection as a new breeding paradigm (nice illustration)