####=========================================####
####random population of 20 lines with 100 markers
####=========================================####
X <- matrix(rep(0,20*100),20,100)
for (i in 1:20) {
X[i,] <- sample(c(-1,0,0,1), size=100, replace=TRUE)
}
E <- E.mat(X, type="A#A")
# if heterozygote markers are present can be used "A#D" or "D#D"
#### Tetraploid additive-by-digenic-dominance epistasis
data(DT_polyploid, package="enhancer")
numo <- enhancer::atcg1234(GT_polyploid[,1:100], ploidy=4, silent=TRUE)
E4 <- E.mat(numo$M, type="A#D", ploidy=4)
Run the code above in your browser using DataLab