View source: R/genomic_eigen_indices.R
| mesim | R Documentation |
Implements the MESIM by maximising the squared accuracy through the generalised eigenproblem combining phenotypic data with molecular marker scores. Unlike Smith-Hazel LPSI, **no economic weights are required**.
mesim(pmat, gmat, S_M, S_Mg = NULL, S_var = NULL, selection_intensity = 2.063)
pmat |
Phenotypic variance-covariance matrix (n_traits x n_traits). |
gmat |
Genotypic variance-covariance matrix (n_traits x n_traits). |
S_M |
Covariance between phenotypes and marker scores (n_traits x n_traits). This represents Cov(y, s) where s are marker scores. Used in the phenotypic variance matrix T_M. |
S_Mg |
Covariance between genetic values and marker scores (n_traits x n_traits). This represents Cov(g, s). Used in the genetic variance matrix Psi_M. If NULL (default), uses S_M, which is appropriate when assuming Cov(e, s) ~= 0 (errors uncorrelated with markers), so Cov(y,s) ~= Cov(g,s). |
S_var |
Variance-covariance matrix of marker scores (n_traits x n_traits). Represents Var(s). If NULL (default), uses S_M for backward compatibility, but providing the actual Var(s) is more statistically rigorous. |
selection_intensity |
Selection intensity constant |
Eigenproblem (Section 8.1):
(\mathbf{T}_M^{-1}\mathbf{\Psi}_M - \lambda_M^2 \mathbf{I}_{2t})\boldsymbol{\beta}_M = 0
where:
\mathbf{T}_M = \begin{bmatrix} \mathbf{P} & \mathrm{Cov}(\mathbf{y},\mathbf{s}) \\ \mathrm{Cov}(\mathbf{s},\mathbf{y}) & \mathrm{Var}(\mathbf{s}) \end{bmatrix}
\mathbf{\Psi}_M = \begin{bmatrix} \mathbf{C} & \mathrm{Cov}(\mathbf{g},\mathbf{s}) \\ \mathrm{Cov}(\mathbf{s},\mathbf{g}) & \mathrm{Var}(\mathbf{s}) \end{bmatrix}
Theoretical distinction:
T_M uses phenotypic covariances: Cov(y, s) provided via S_M
Psi_M uses genetic covariances: Cov(g, s) provided via S_Mg
Since y = g + e, if Cov(e, s) ~= 0, then Cov(y, s) ~= Cov(g, s)
Chapter 8.1 assumes marker scores are pure genetic predictors, so S_M can be used for both (default behavior when S_Mg = NULL)
The solution \lambda_M^2 (largest eigenvalue) equals the maximum
achievable index heritability.
Key metrics:
R_M = k_I \sqrt{\boldsymbol{\beta}_{M}^{\prime}\mathbf{T}_M\boldsymbol{\beta}_{M}}
\mathbf{E}_M = k_I \frac{\mathbf{\Psi}_M\boldsymbol{\beta}_{M}}{\sqrt{\boldsymbol{\beta}_{M}^{\prime}\mathbf{T}_M\boldsymbol{\beta}_{M}}}
Object of class "mesim", a list with:
summaryData frame with coefficients and metrics.
b_yCoefficients for phenotypic data.
b_sCoefficients for marker scores.
b_combinedCombined coefficient vector.
E_MExpected genetic gains per trait.
sigma_IStandard deviation of the index.
hI2Index heritability (= leading eigenvalue).
rHIAccuracy r_{HI}.
R_MSelection response.
lambda2Leading eigenvalue (maximised index heritability).
selection_intensitySelection intensity used.
Ceron-Rojas, J. J., & Crossa, J. (2018). Linear Selection Indices in Modern Plant Breeding. Springer International Publishing. Section 8.1.
## Not run:
gmat <- gen_varcov(seldata[, 3:9], seldata[, 2], seldata[, 1])
pmat <- phen_varcov(seldata[, 3:9], seldata[, 2], seldata[, 1])
# Simulate marker score matrices (in practice, compute from data)
S_M <- gmat * 0.7 # Cov(y, s) - phenotype-marker covariance
S_Mg <- gmat * 0.65 # Cov(g, s) - genetic-marker covariance
S_var <- gmat * 0.8 # Var(s) - marker score variance
# Most rigorous: Provide all three covariance matrices
result <- mesim(pmat, gmat, S_M, S_Mg = S_Mg, S_var = S_var)
print(result)
# Standard usage: Cov(g,s) defaults to Cov(y,s) when errors uncorrelated
result_standard <- mesim(pmat, gmat, S_M, S_var = S_var)
# Backward compatible: Chapter 8.1 simplified notation
result_simple <- mesim(pmat, gmat, S_M)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.