RelCoefLine: Relatedness Coefficients Estimation for Lines

Description Usage Arguments Value Author(s) Examples

View source: R/RelCoefLine.R

Description

This function performs Maximum Likelihood estimation for the relatedness coefficients between lines based on a bi-allelic genotype matrix.

Usage

1
2
3
4
5
RelCoefLine(LineGenom = matrix(0,nrow=0,ncol=0), 
	    Freq = matrix(0,nrow=0,ncol=0), 
	    LinePop = rep(0,0), 
	    Combination = NULL, 
	    NbInit = 5, Prec = 10^(-4), NbCores = NULL)

Arguments

LineGenom

Genotype matrix of lines. Each line is described by 1 column. Each row corresponds to a marker. Entries of matrix Genotype should be either 0 or 1.

Freq

Allelic frequencies for allele 1 at each markers and for all populations (one column per population, one line per marker).

LinePop

A vector of numbers corresponding to population membership for the parental lines.

Combination

If provided, a list of vector with two components. The jth vector is composed with the number of the first hybrid and the number of the second hybrid of the jth couple to study.

NbInit

Number of initial values for the EM algorithm.

Prec

Convergence precision parameter for the EM algorithm.

NbCores

Number of cores used by the algorithm (Default is the number of cores available minus one). Only available for linux and Mac.

Value

By default, relatedness coefficients are displayed for all couple of genotyped lines. In that case the function returns a matrix corresponding to the Simple Relatedness Coefficient, i.e. the probability that each couple of lines are related. Element (i,j) of the matrix corresponds to the estimated relatedness coefficient for the couple of lines i and j. Alternatively, if a list of couples is specified with argument Combination, the function returns a list of coefficients (each coefficient corresponding to an relatedness coefficient). In that case element i of the list corresponds to the estimated relatedness coefficient of the ith couple specified in Combination.

Author(s)

Fabien Laporte, 'UMR Genetique Quantitative et Evolution' INRA France.

Examples

1
2
3
4
5
6
7
require('Relatedness')
data(Genotype)
data(Frequencies)
data(Cross)
SimpleRelatedness <- RelCoefLine(LineGenom=Genotype,Freq=Frequencies,
LinePop=rep(1,8),NbCores=2)
print(SimpleRelatedness)

Example output

     [,1]      [,2]      [,3]      [,4]      [,5]      [,6]      [,7]      [,8]
[1,]    1 0.1868284 0.1549552 0.1772894 0.1654438 0.1624531 0.1327285 0.1570069
[2,]    0 1.0000000 0.1257682 0.1595428 0.1548326 0.1541947 0.1305496 0.1662445
[3,]    0 0.0000000 1.0000000 0.1424444 0.1368720 0.1681483 0.1664988 0.1437298
[4,]    0 0.0000000 0.0000000 1.0000000 0.1554573 0.1680825 0.1552717 0.1777461
[5,]    0 0.0000000 0.0000000 0.0000000 1.0000000 0.1630341 0.1381541 0.1535189
[6,]    0 0.0000000 0.0000000 0.0000000 0.0000000 1.0000000 0.1221635 0.1603285
[7,]    0 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 1.0000000 0.1706520
[8,]    0 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 0.0000000 1.0000000

Relatedness documentation built on May 2, 2019, 11:11 a.m.