safety_first_index {toolStability} | R Documentation |
Safety-first Index
Description
safety_first_index
calculate variance of a genotype across environments.
Usage
safety_first_index(data, trait, genotype, environment, lambda)
Arguments
data |
a dataframe containing trait, genotype and environment. |
trait |
colname of a column containing a numeric vector of interested trait to be analyzed. |
genotype |
colname of a column containing a character or factor vector labeling different genotypic varieties. |
environment |
colname of a column containing a character or factor vector labeling different environments. |
lambda |
the minimal acceptable value of trait that the user expected from crop across environments. Lambda should between the ranges of trait vlaue. |
Details
Safety-first index (Eskridge, 1990) is calculated based on the assumption of
that the trait from each genotype follows normal distribution over enviornments.
Among different environments, trait below a given cirtical level \lambda
is defined as failure of trait. The probability of trait failure can be obtained
by entering mean and variance of trait and \lambda
into the cumulated density function of normal distribution.
Variety with low safety first index is considered as stable.
Equation of adjusted coefficient of variation can be found in vignette file.
Value
a data table with coefficient of determination
Author(s)
Tien-Cheng Wang
References
Eskridge KM (1990). “Selection of Stable Cultivars Using a Safety-First Rule.” Crop Science, 30(2), 369. ISSN 0011-183X, doi: 10.2135/cropsci1990.0011183X003000020025x.
Examples
data(Data)
safety.first.index <- safety_first_index(
data = Data,
trait = "Yield",
genotype = "Genotype",
environment = "Environment",
lambda = median(Data$Yield))