NOIA matrix manipulation {noia} | R Documentation |
These functions perform the matrix computation required for the computation of geneticEffects and Genotype-to-Phenotype mapping.
gen2Z(gen) gen2genZ(gen) genZ2freq(genZ) genZ2S(type="F2", genZ=NULL, nloc=NULL) genZ2Z(genZ) Z2freq(Z) Sloc(type="F2", i=NULL, genZ=NULL)
gen |
The matrix of genotypes, one column per locus, the genotype is
coded 1 , 2 , 3 . Missing data are allowed. |
genZ |
The matrix of genotypic probabilities, 3 columns per locus (one for the probability of each genotype). The sum of probabilities must be 1, and missing data are not allowed. |
type |
The type of the population. "F2" , "F1" ,
"Finf" . "P1" , "P2 , "G2A" , "UWR" and
"noia" are possible. Default is "F2" . |
nloc |
Number of loci. |
Z |
A matrix reflecting the genotype of the corresponding observed phenotypes, as defined in Alvarez-Castro and Carlborg 2007. |
i |
Index of the locus. |
gen2Z
gen
data set into a Z
matrix that
is the data matrix in the regression. The function actually calls sequencially
gen2genZ
and genZ2Z
. gen2genZ
gen
matrix into a genZ
matrix. genZ2freq
genZ2S
S
matrix (see Alvarez-Castro and Carlborg
2007) for a given reference point. Some reference points are genotypic
frequency-dependent ("G2A"
and "noia"
), and the genZ
matrix must be provided. For the others, only the number of loci is
necessary. genZ2Z
Z
matrix from the genotypic
probabilities. See Alvarez-Castro and Carlborg 2007 for more details. Z2freq
Sloc
S
matrix, corresponding to one locus.
Frequency-dependent reference points will require the genZ
matrix
and the index of the locus. Arnaud Le Rouzic <a.p.s.lerouzic@bio.uio.no>
Alvarez-Castro JM, Carlborg O. (2007). A unified model for functional and statistical epistasis and its application in quantitative trait loci analysis. Genetics 176(2):1151-1167.
Le Rouzic A, Alvarez-Castro JM. (2008). Estimation of genetic effects and genotype-phenotype maps. Evolutionary Bioinformatics, in press.
linearRegression
, multilinearRegression
set.seed(123456789) map <- c(0.25, -0.75, -0.75, -0.75, 2.25, 2.25, -0.75, 2.25, 2.25) names(map) <- genNames(2) pop <- simulatePop(map, N=500, sigmaE=0.2, type="F2") gen <- pop[2:3] genZ <- gen2genZ(gen) Z <- genZ2Z(genZ)