library(qtl)
# marker map
map <- sim.map(len=rep(100, 19), n.mar=10, include.x=FALSE)
# simulate AIL pedigree
tab <- sim_ail_pedigree(12, 30)
# simulate data from that pedigree
dat <- sim_from_pedigree_allchr(tab, map)
names(map) <- paste0("marker", seq(along=map))
# convert data to marker genotypes
id <- which(tab[, "gen"]==12)
geno <- convert2geno_allchr(dat, map, id)
Run the code above in your browser using DataLab