Description Usage Arguments Details Value References See Also Examples
View source: R/Make_cross_v11_Commented.R
This function can be used for crossing between populations. Different crossbreeding schemes such as two-way, three-way and four-way crossbreeding schemes can be simulated.
1 2 3 4 | xbreed(pop1, pop2, founder_pop1, founder_pop2, founder_cross, Selection_pop1,
Selection_pop2, Cross_design, ng, litter_size, train_type, train_pop1,
train_pop2, train_cross, saveAt, output_pop1, output_pop2, output_cross,
Display)
|
pop1 |
( |
pop2 |
( |
founder_pop1 |
(
Column 4) "value" Indicates to select high: "h" or low: "l" values. Note: This colomn is ignored if individuals are selected randomly. |
founder_pop2 |
( |
founder_cross |
(
Column 2) "size" is the number of individuals to be selected.
Column 4) "value" Indicates to select high: "h" or low: "l" values. This column is ignored if individuals are selected randomly. |
Selection_pop1 |
(
Column 3) "value" Indicates to select high: "h" or low: "l" values. Note: This colomn is ignored if individuals are selected randomly. |
Selection_pop2 |
( |
Cross_design |
(
As an example if row 1 and column 1 of argument
Column 4) "value" Indicates to select high: "h" or low: "l" values. Note: This column is ignored if individuals are selected randomly. |
ng |
Number of generations. Range: 1 ≤q \code{ng} ≤q 200. |
litter_size |
Litter size or the number of progeny per dam. Range: 1 ≤q \code{x} ≤q 200. |
train_type |
Optional (
Note: If selection criteria for any population is defined as gebv/gebvc, argument |
train_pop1 |
Optional (
Default: "rnd"
Default: "BRR" |
train_pop2 |
Optional ( |
train_cross |
Optional ( |
saveAt |
Optional ( |
output_pop1 |
Optional ( |
output_pop2 |
Optional ( |
output_cross |
Optional ( |
Display |
Optional ( |
Function xbreed
is used for crossing between populations. These populations can be the ones created by functions sample_hp
and make_rp
. Also, if user would like to have multi-way crossbreeding schemes such as three-way crossbreeding, then function xbreed
can be used to get the output of itself as input data in order to create the multi-way crossbreed populations. Simulations of two-way and multi-way crossbreeding schemes are presented in the package vignette.
list
with all data of simulated populations.
(list
) Two-level list ($pop1[[]][[]]
) containing information about simulated generations. First index (x) indicates generation number. It should be noted that as data for base generation (0) is also stored by the function, to retrive data for a specific generation, index should be equal to generation number plus one. As an example to observe data for generation 2 index should be 3 i.e, $pop1[[3]]$data
. Second index (y) that ranges from 1 to 6 contain the information as following:
$pop1[[x]]$data
Individuals data except their genotypes. Here x is the generation index.
$pop1[[x]]$qtl
QTL genotye of individuals.
$pop1[[x]]$mrk
Marker genotye of individuals.
$pop1[[x]]$sequ
Genotype (both marker (SNP) and QTL) of individuals.
$pop1[[x]]$freqQTL
QTL allele frequency.
$pop1[[x]]$freqMRK
Marker allele frequency.
Similar to $pop1
(list
) Two-level list ($cross$output[[x]][[y]]
) containing information about simulated crossbred generations. Details are similar to $pop1
such as:
$cross$output[[x]]$data
Crossbred individuals data except their genotypes. Here x is the generation index.
$cross$output[[x]]$qtl
QTL genotye of crossbred individuals.
$cross$output[[x]]$mrk
Marker genotye of individuals.
$cross$output[[x]]$sequ
Genotype (both marker (SNP) and QTL) of individuals.
$cross$output[[x]]$freqQTL
QTL allele frequency.
$cross$output[[x]]$freqMRK
Marker allele frequency.
Data frame with summary of simulated crossbreds
.
Data frame with summary of simulated generations for pop1 (Breed 1)
.
Data frame with summary of simulated generations for pop2 (Breed 2)
.
Linkage map for qtl
.
Linkage map for marker
.
Integrated linkage map for both marker and qtl
.
QTL allele effects
.
Trait specifications
.
Genome specifications
.
Esfandyari H., A.C Sorensen and P. Bijma. 2015. A crossbred reference population can improve the response to genomic selection for crossbred performance. Genetics Selection Evolution 47: 76
Esfandyari H., A.C Sorensen and P. Bijma. 2015. Maximizing crossbred performance through purebred genomic selection. Genetics Selection Evolution 47: 16
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | ## Not run:
# # Simulation of a two-way crossbreeding program.
# The crossbreeding scheme in this example involves three steps:
#Step 1: Historical population is created.
#Step 2: Two recent populations named as Breed A and B
# are created by sampling individuals from historical population.
#Step 3: Breed A and B are crossed.
#--------------------------------------
# # STEP 1: CREATE HISTORICAL POPULATION
# Genome consisted of 3 chromosomes
genome<-data.frame(matrix(NA, nrow=3, ncol=6))
names(genome)<-c("chr","len","nmrk","mpos","nqtl","qpos")
genome$chr<-c(1:3)
genome$len<-rep(100,3)
genome$nmrk<-rep(100,3)
genome$mpos<-rep('rnd',3)
genome$nqtl<-rep(25,3)
genome$qpos<-rep('rnd',3)
genome
historical<-make_hp(hpsize=300
,ng=10,h2=0.25,d2=0.10,phen_var=1
,genome=genome,mutr=5*10**-4,laf=0.5)
# # STEP 2: MAKE BREED A AND B
# BREED A
Breed_A_Male_fndrs<-data.frame(number=50,select='rnd')
Breed_A_Female_fndrs<-data.frame(number=50,select='rnd')
# Selection and matings in Breed A
# Selection of 50 sires and 50 dam
# Selection criteria is "rnd" for both sires and dams
Selection<-data.frame(matrix(NA, nrow=2, ncol=2))
names(Selection)<-c("Number","type")
Selection$Number[1:2]<-c(50,50)
Selection$type[1:2]<-c("rnd","rnd")
Selection
Breed_A<-sample_hp(hp_out=historical,Male_founders=
Breed_A_Male_fndrs,Female_founders=Breed_A_Female_fndrs,
ng=5,Selection=Selection,
litter_size=3,Display=TRUE)
# BREED B
Breed_B_Male_fndrs<-data.frame(number=50,select="rnd")
Breed_B_Female_fndrs<-data.frame(number=50,select="rnd")
# Selection and matings in Breed B
# Selection of 50 sires and 50 dam
# Selection criteria is "phen" for both sires and dams
Selection<-data.frame(matrix(NA, nrow=2, ncol=3))
names(Selection)<-c("Number","type","Value")
Selection$Number[1:2]<-c(50,50)
Selection$type[1:2]<-c("phen","phen")
Selection$Value[1:2]<-c("h","h")
Selection
Breed_B<-sample_hp(hp_out=historical,Male_founders=
Breed_B_Male_fndrs,Female_founders=Breed_B_Female_fndrs,
ng=5,Selection=Selection,
litter_size=3,Display=TRUE)
# # STEP 3: CROSSING BETWEEN BREED A AND B
# Selection of founders in crossbreeding for Breed A
# Selection of 50 sires and 50 dams
# from last generation of pop in step 2.
# Selection criteria is "rnd" for both sires and dams
founder_pop1<-data.frame(matrix(NA, nrow=2, ncol=3))
names(founder_pop1)<-c("size","generation","select")
founder_pop1[1,]<-c(50,5,"rnd")
founder_pop1[2,]<-c(50,5,"rnd")
founder_pop1
# Selection of founders in crossbreeding for Breed B
# Selection of 40 sires and 40 dams
# Selection criteria is "phen" for sires
# Selection criteria is "rnd" for dams
founder_pop2<-data.frame(matrix(NA, nrow=2, ncol=4))
names(founder_pop2)<-c("size","generation","select","value")
founder_pop2[1,]<-c(40,5,"phen","h")
founder_pop2[2,]<-c(40,5,"rnd","h") # "h" will be ignored as SC is "rnd"
founder_pop2
# Selection of animals from founder_pop1 and founder_pop2 to be crossed
founder_cross<-data.frame(matrix(NA, nrow=2, ncol=4))
names(founder_cross)<-c("pop","size","select","value")
founder_cross[1,]<-c("pop1",35,"tbv","h") # Select males from Breed A
founder_cross[2,]<-c("pop2",40,"phen","h") # Select females from Breed B
founder_cross
# Selection scheme in Breed A to produce purebred replacement animals
Selection_pop1<-data.frame(matrix(NA, nrow=2, ncol=3))
names(Selection_pop1)<-c("Number","type","Value")
Selection_pop1$Number[1:2]<-c(70,70)
Selection_pop1$type[1:2]<-c("tbv","tbv")
Selection_pop1$Value[1:2]<-c("h","h")
Selection_pop1
# Selection scheme in Breed B to produce purebred replacement animals
Selection_pop2<-data.frame(matrix(NA, nrow=2, ncol=3))
names(Selection_pop2)<-c("Number","type","Value")
Selection_pop2$Number[1:2]<-c(40,40)
Selection_pop2$type[1:2]<-c("phen","phen")
Selection_pop2$Value[1:2]<-c("h","h")
Selection_pop2
# Selection scheme for crossing between A and B
Cross_design<-data.frame(matrix(NA, nrow=2, ncol=4))
names(Cross_design)<-c("pop","size","select","value")
Cross_design[1,]<-c("pop1",50,"phen","h")
Cross_design[2,]<-c("pop2",100,"phen","h")
Cross_design
# Save data for crossbred AB
output_cross<-data.frame(matrix(NA, nrow=1, ncol=1))
output_cross[,1]<-c(1)
output_cross
cross_AB<-xbreed(pop1=Breed_A,pop2=Breed_B,founder_pop1=
founder_pop1,founder_pop2=founder_pop2,
founder_cross=founder_cross,
Selection_pop1=Selection_pop1,Selection_pop2=Selection_pop2,
Cross_design=Cross_design,ng=2,litter_size=4,
saveAt="cross_pop",output_cross=output_cross,Display=TRUE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.