validation.blup: Cross-validation for blup prediction

Description Usage Arguments Details Author(s) See Also Examples

View source: R/validation.blup.R

Description

Cross-validation for blup prediction.

Usage

1
2
validation.blup(.data, resp, gen, env, rep,
                nboot, nrepval, verbose = TRUE)

Arguments

.data

The dataset containing the columns related to Environments, Genotypes, replication/block and response variable(s).

resp

The response variable.

gen

The name of the column that contains the levels of the genotypes.

env

The name of the column that contains the levels of the environments.

rep

The name of the column that contains the levels of the replications/blocks.

nboot

The number of resamples to be used in the cross-validation

nrepval

The number of replicates (r) from total number of replicates (R) to be used in the modeling dataset. Only one replicate is used as validating data each step, so, Nrepval must be equal R-1

verbose

A logical argument to define if a progress bar is shown. Default is TRUE.

Details

This function provides a cross-validation procedure for mixed models using replicate-based data. By default, complete blocks are randomly selected within each evironment. In each iteraction, the original dataset is split up into two datasets: training and validation data. The "training" set has all combinations (genotype x environment) with the number of replications informed in nrepval. The "validation" set has the remaining replication. The estimated values are compared with the "validation" data and the Root Means Square Prediction Difference is computed. At the end of boots, a list is returned.

Author(s)

Tiago Olivoto [email protected]

See Also

plot.scores, plot.WAASBY

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 
library(METAAB)
model = validation.blup(data_ge,
                        resp = GY,
                        gen = GEN,
                        env = ENV,
                        rep = REP,
                        nboot = 100,
                        nrepval = 2)

# Alternatively (and more intuitively) using the pipe operator %>%
library(dplyr)
model = data_ge %>%
        validation.blup(GY, GEN, ENV, REP, 100, 2)


## End(Not run)

TiagoOlivoto/WAASB documentation built on April 1, 2019, 10:25 a.m.