Description Usage Arguments Value References Examples
Bayesian Multi-Environment Model (BME)
1 2 3 4 5 6 7 8 9 10 11 12 |
Y |
|
Z1 |
|
nIter |
|
burnIn |
|
thin |
|
bs |
|
parallelCores |
|
digits |
|
progressBar |
|
testingSet |
|
If the testingSet is NULL, the function returns the predictions.
Else, if the testingSet is not NULL, the function returns the correlation of the predictions of the cross-validation test.
Montesinos-Lopez, O.A., Montesinos-Lopez, A., Crossa, J., Toledo, F.H., Perez-Hernandez, O., Eskridge, K.M., … Rutkoski, J. (2016). A Genomic Bayesian Multi-trait and Multi-environment Model. G3: Genes|Genomes|Genetics, 6(9), 2725–2744. https://doi.org/10.1534/g3.116.032359.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | data("WheatMadaToy")
phenoMada <- (phenoMada[order(phenoMada$GID),])
#Matrix design
LG <- cholesky(genoMada)
ZG <- model.matrix(~0 + as.factor(phenoMada$GID))
Z.G <- ZG %*% LG
#Pheno data
Y <- as.matrix(phenoMada[, -c(1)])
# Check fitting
fm <- BME(Y = Y, Z1 = Z.G, nIter = 10000, burnIn = 5000, thin = 2, bs = 50)
# Check predictive capacities of the model with CrossValidation object
pheno <- data.frame(GID = phenoMada[, 1], Env = '', Response = phenoMada[, 3])
CrossV <- CV.RandomPart(pheno, NPartitions = 4, PTesting = 0.2, set_seed = 123)
pm <- BME(Y = Y, Z1 = Z.G, nIter = 10000, burnIn = 5000, thin = 2, bs = 50, testingSet = CrossV)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.