expandAmatrix {AGHmatrix} | R Documentation |
Add new crosses to a current A matrix
Description
Expand a current A matrix with a new pedigree. The parents in the new pedigree should also be in the A matrix.
Usage
expandAmatrix(newPedigree = NULL, A = NULL, returnAll = TRUE)
Arguments
newPedigree |
pedigree data name (3-column way format). Unknown value should be equal 0. |
A |
numerator relationship matrix output from Amatrix function. |
returnAll |
if TRUE returns old A with new A, if FALSE returns only new A |
Value
Matrix with the Relationship between the individuals.
Author(s)
Rodrigo R Amadeu, rramadeu@gmail.com
Examples
data(ped.sol)
ped.initial = ped.sol[1:1120,]
ped.new = ped.sol[-c(1:1120),]
#Computing additive relationship matrix:
A = Amatrix(ped.initial, ploidy=2)
Anew = expandAmatrix(ped.new, A)
#Comparing with one-step building..
Afull = Amatrix(ped.sol, ploidy=2)
test = Anew-Afull
which(test!=0)
[Package AGHmatrix version 2.1.4 Index]