The aim of optimum contribution selection is to find the optimum number of offspring for each breeding animal and to determine if a young animal (a selection candidate) should be selected for breeding or not. This is done in an optimal way, i.e. in a way that ensures that genetic gain is achieved, and that genetic diversity and genetic originality of the population are maintained or recovered. It can be based either on pedigree data or on marker data, whereby the latter approach is recommended. It requires that this data is available for all selection candidates, or, at least from a large sample of selection candidates.
Even if the frequency of use of breeding animals is not regulated by the breeding organization, running the optimization still provides valuable information for a breeder, as the animals with highest optimum contributions are most valuable for a breeding program.
This vignette is organized as follows:
All evaluations using marker data are demonstrated at the example of cattle data included in the package. This multi-breed data has already been described in the companion vignette for basic marker-based evaluations.
Data frame Cattle
includes the phenotypic information and has columns Indiv
(individual IDs), Born
(year of birth), Breed
(breed name), BV
(breeding values), Sex
(sexes), and herd
(herd).
library("optiSel")
data(Cattle)
head(Cattle)
## Indiv Born Breed BV Sex herd
## 276000101676415 276000101676415 1991 Angler -1.0706066 male <NA>
## 276000108612636 276000108612636 1994 Angler -0.3362574 female 2
## 276000102372349 276000102372349 1986 Angler -2.0735649 female 1
## 276000102379430 276000102379430 1987 Angler 1.5968307 male <NA>
## 276000108826036 276000108826036 1994 Angler 1.0023969 male <NA>
## 276000111902076 276000111902076 1998 Angler -0.2426676 male <NA>
The data frame contains information on the 4 breeds Angler, Fleckvieh, Holstein, Rotbunt. The “Angler” is an endangered German cattle breed, which had been upgraded with Red Holstein (also called “Rotbunt”). The Rotbunt cattle are a subpopulation of the “Holstein” breed. The “Fleckvieh” or Simmental breed is unrelated to the Angler. The Angler cattle are the selection candidates.
This small example data set contains only genotypes from the first parts of the first two chromosomes. Vector GTfiles
defined below contains the names of the genotype files. There is one file for each chromosome. Data frame map
contains the marker map and has columns Name
(marker name), Chr
(chromosome number), Position
, Mb
(position in Mega base pairs), and cM
(position in centiMorgan):
data(map)
dir <- system.file("extdata", package="optiSel")
GTfiles <- file.path(dir, paste("Chr", unique(map$Chr), ".phased", sep=""))
head(map)
## Name Chr Position cM Mb
## ARS-BFGL-NGS-16466 ARS-BFGL-NGS-16466 1 267940 0 0.267940
## ARS-BFGL-NGS-98142 ARS-BFGL-NGS-98142 1 471078 0 0.471078
## ARS-BFGL-NGS-114208 ARS-BFGL-NGS-114208 1 533815 0 0.533815
## ARS-BFGL-NGS-65067 ARS-BFGL-NGS-65067 1 883895 0 0.883895
## ARS-BFGL-BAC-32722 ARS-BFGL-BAC-32722 1 929617 0 0.929617
## ARS-BFGL-BAC-34682 ARS-BFGL-BAC-34682 1 950841 0 0.950841
As an introductory example you may run a traditional OCS with marker based kinship matrices. All alternative approaches involve the same steps, so it is recommended to read this section even if you want to minimize inbreeding instead of maximizing genetic gain. The following steps are involved:
Define a data frame containing the phenotypes of the selection candidates. Make sure that there is one column for each trait that should be improved.
phen <- Cattle[Cattle$Breed=="Angler",]
Compute the kinships that are to be managed. Below, the kinship is named sKin
, which is a shorthand for segment based kinship.
sKin <- segIBD(GTfiles, map)
## Using skip = 2
## Using cskip = 2
## Reading chromosome 1 ...M=400
## Reading chromosome 2 ...M=400
Create variable cand
with function candes, containing all information required to describe the candidates, which are the phenptypes and the kinships. The current values of the parameters and the available objective functions and constraints are shown.
cand <- candes(phen=phen, sKin=sKin)
##
## Mean values of the parameters are: Value
## for trait 'BV' in Angler: 0.0394
## for kinship 'sKin' in Angler: 0.0570
##
## Available objective functions and constraints:
## for trait 'BV' in Angler: min.BV, max.BV, lb.BV, eq.BV, ub.BV
## for kinship 'sKin' in Angler: min.sKin, ub.sKin
##
## ub lb uniform
For numeric columns in data frame phen
the possibility is provided to define an upper bound (prefix ub
), a lower bound (prefix lb
), an equality constraint (prefix eq
), or to minimize (prefix min
) or to maximize (prefix max
) the weighted sum of the values, whereby the weights are the contributions of the selection candidates. If the column contains breeding values, then this is the expected mean breeding value in the offspring.
For each kinship and native kinship included in the call of function candes, the possibility is provided to define an upper bound for the expected mean value of the kinship in the offspring (prefix ub
), or to minimize the value (prefix min
).
Constraints ub
and lb
allow to define upper bounds and lower bounds for the contributions of the selection candidates. Constraint uniform
allows to assume that individuals belonging to specified groups have equal contributions.
Now choose the parameters you want to restrict and the parameters you want to optimize. For traditional OCs the objective is to maximize genetic gain with method max.BV
, and to restrict the mean kinship in the offspring by defining constraint ub.sKin
.
Create an empty list for the constraints:
con <- list()
and put the constraints into the list. To assume equal contributions for the females you may define component uniform
as
con$uniform <- "female"
In this case, the contributions of males will be optimized, but all females have equal numbers of offspring. Upper and lower bounds for the contributions of selection candidates could be defined with lb
and ub
(see the help page of function opticont).
The upper bound for the mean kinship in the offspring should depend on the mean kinship in the current generation, which is included in component mean
of cand
. Both sexes contribute equally to these estimates.
cand$mean
## BV sKin
## 1 0.0393541 0.05701273
To define an upper bound for the mean kinship sKin
in the offspring, put component ub.sKin
into list con
. In general, if an upper bound for a kinship \(K\) should be defined, it is recommended to derive the threshold value from the desired effective size \(N_e\) of the population by the formula \[ub.K=\overline{K}+(1-\overline{K})\Delta F,\] where \(\overline{K}\) is the mean kinship in the current generation, which has been estimated above, and \(\Delta F=\frac{1}{2 N_e}\). The critical effective size, i. e. the size below which the fitness of the population steadily decreases, depends on the population and is usually between 50 and 100. But there seems to be a consensus that 50-100 is a long-term viable effective size. To be on the safe side, an effective size of \(N_e=100\) should be envisaged (T H E Meuwissen 2009). Thus, the constraint is defined as
Ne <- 100
con$ub.sKin <- cand$mean$sKin + (1-cand$mean$sKin)*(1/(2*Ne))
Now the optimum contributions of the selection candidates can be calculated:
Offspring <- opticont("max.BV", cand, con, trace=FALSE)
##
## Using solver 'cccp2' with parameters:
## Value
## trace 0
## abstol 1e-05
## feastol 1e-05
## stepadj 0.9
## maxiters 100
## reltol 1e-06
## beta 0.5
##
## valid solver status
## TRUE cccp2 optimal
##
## Variable Value Bound OK?
## --------------------------------------------------
## BV Angler 1.0221 max :
## --------------------------------------------------
## lower bounds all x >= lb : TRUE
## upper bounds all x <= ub : TRUE
## breed contribution Angler 1 == 1 : TRUE
## sex contrib. diff. Angler 0 == 0 : TRUE
## BV Angler 1.0221 :
## sKin Angler 0.0617 <= 0.0617 : TRUE
## --------------------------------------------------
The report above states that the solution is considered optimal by the solver and that all constraints are fulfilled since valid=TRUE. This information can also be obtained as
Offspring$info
## valid solver status
## 1 TRUE cccp2 optimal
The value of the objective function can be accessed as
Offspring$obj.fun
## BV
## 1.022091
and the expected average values of the kinshps and traits in the offspring are
Offspring$mean
## BV sKin
## 1 1.022091 0.06172791
The results are OK. If they are not, then try to use another solver. The solver can be specified in parameter solver
of function opticont. Available solvers are "alabama"
, "cccp"
, "cccp2"
, "csdp"
, and "slsqp"
. By default the solver is chosen automatically. Alternatively, the same solver may be used but with different tuning parameters. The available paramters are displayed if the function opticont is called (as shown above).
The optimum contributions of the selection candidates are in component parent
:
Candidate <- Offspring$parent[, c("Indiv", "Sex", "oc")]
head(Candidate[rev(order(Candidate$oc)),])
## Indiv Sex oc
## 276000121507437 276000121507437 male 0.06558561
## 276000121243787 276000121243787 male 0.06393463
## 276000120949468 276000120949468 male 0.05971273
## 276000120061822 276000120061822 male 0.05867668
## 276000110948577 276000110948577 male 0.05445245
## 276000113913566 276000113913566 male 0.04079488
The optimum numbers of offspring can be obtained from the optimum contributions and the size N
of the offspring population with function noffspring:
Candidate$nOff <- noffspring(Candidate, N=250)$nOff
head(Candidate[rev(order(Candidate$oc)),])
## Indiv Sex oc nOff
## 276000121507437 276000121507437 male 0.06558561 33
## 276000121243787 276000121243787 male 0.06393463 32
## 276000120949468 276000120949468 male 0.05971273 30
## 276000120061822 276000120061822 male 0.05867668 29
## 276000110948577 276000110948577 male 0.05445245 27
## 276000113913566 276000113913566 male 0.04079488 20
Males and females can be allocated for mating with function matings such that all breeding animals have the desired number of offspring. In the example below the mean marker-based inbreeding coefficient in the offspring is minimized. Since the default value for parameter N
is used, it is assumed that females have 2 offspring on average available as selection candidates in the next generation. Parameter alpha=0.3
means that in each herd at most 30% of the cows are mated with the same bull. This increases genetic connectedness between herds and enables to estimate more accurate breeding values.
Mating <- matings(Candidate, Kin=sKin)
## Optimal branch and bound solution found
head(Mating)
## Sire Dam nOff
## 1 276000113913566 276000108612636 2
## 2 276000121243787 276000102372349 2
## 3 276000121507437 276000110204007 2
## 4 276000120949468 276000111909505 2
## 5 276000120949468 276000111901935 2
## 6 276000102379430 276000110948587 2
The mean inbreeding in the offspring (which is equal to the mean kinship of the parents) is:
attributes(Mating)$objval
## [1] 0.004454881
The objective of a breeding program depends on several factors. These are the intended use of the breed, the presence of historic bottlenecks, and the importance being placed on the maintenance of genetic originality. In most livestock breeds the focus is on increasing the economic merit, so the objective of the breeding program is to maximize genetic gain. In contrast, companion animals often suffer from historic bottlenecks due to an overuse of popular sires. Hence, in these breeds the objective is to minimize inbreeding. In endangered breeds, which get subsidies for conservation, the focus may be on increasing their conservation values by recovering the native genetic background or by increasing the genetic distance to other breeds.
However, these are conflicting objectives: To maximize genetic gain, the animals with highest breeding values would be used for breeding, which may create a new bottleneck and contribute to inbreeding depression. Maximizing genetic gain would also favor the use of animals with high genetic contributions from commercial breeds because these animals often have the highest breeding values. But this would reduce the genetic originality of the breed. Minimizing inbreeding in the offspring favors the use of animals with high contributions from other breeds because they have low kinship with the population and it may require the use of outcross animals with breeding values below average.
Thus, focussing on only one aspect automatically worsens the other ones. This can be avoided by imposing constraints on the aspects that are not optimized.
In general, best practice is genotying all selection candidates to enable marker based evaluations. A breeding program based on marker information is more efficient than a breeding program based only on pedigree information, provided that the animals are genotyped for a sufficient number of markers. For several species, however, genotyping is still too expensive, so the breeding programs rely only on pedigree information.
Depending on what the objective of the breeding program is, you may continue reading at the appropriate section:
The required genotype file format, the marker map, the parameters minSNP
, minL
, unitL
, unitP
, and ubFreq
, which are used for estimating the segment based kinship, the kinships at native haplotype segments, and the breed composition, have been described in the companion vignette for basic marker-based evaluations.
The breed composition of individuals can be estimated with function segBreedComp. Since native contributions NC
of the Angler cattle should be considered, they are computed and added as an additional column to data frame Cattle
.
wdir <- file.path(tempdir(), "HaplotypeEval")
wfile <- haplofreq(GTfiles, Cattle, map, thisBreed="Angler", minL=1.0, w.dir=wdir)
Comp <- segBreedComp(wfile$match, map)
Cattle[rownames(Comp), "NC"] <- Comp$native
head(Cattle[,-1])
## Born Breed BV Sex herd NC
## 276000101676415 1991 Angler -1.0706066 male <NA> 0.5805690
## 276000108612636 1994 Angler -0.3362574 female 2 0.5687157
## 276000102372349 1986 Angler -2.0735649 female 1 0.7418098
## 276000102379430 1987 Angler 1.5968307 male <NA> 0.4045441
## 276000108826036 1994 Angler 1.0023969 male <NA> 0.2239983
## 276000111902076 1998 Angler -0.2426676 male <NA> 0.2458519
A matrix containing the segment based kinship between all pairs of individuals can be computed with function segIBD, whereas the kinships at native haplotype segments can be calculated from the results of function segIBDatN. Both kinships are computed below. These kinships and the phenotypes of the selection candidates are combined into a single R-object with function candes. This function computes also the current values of the parameters and displays the available objective functions and constraints. Below, the kinship at native haplotype segments is named sKinatN
:
phen <- Cattle[Cattle$Breed=="Angler",]
sKin <- segIBD(GTfiles, map, minL=1.0)
sKinatN <- segIBDatN(GTfiles, Cattle, map, thisBreed="Angler", minL=1.0)
cand <- candes(phen=phen, sKin=sKin, sKinatN=sKinatN)
##
## Mean values of the parameters are: Value
## for trait 'BV' in Angler: 0.0394
## for trait 'NC' in Angler: 0.3851
## for kinship 'sKin' in Angler: 0.0570
## for nat. kin. 'sKinatN' in Angler: 0.0671
##
## Available objective functions and constraints:
## for trait 'BV' in Angler: min.BV, max.BV, lb.BV, eq.BV, ub.BV
## for trait 'NC' in Angler: min.NC, max.NC, lb.NC, eq.NC, ub.NC
## for kinship 'sKin' in Angler: min.sKin, ub.sKin
## for nat. kin. 'sKinatN' in Angler: min.sKinatN, ub.sKinatN
##
## ub lb uniform
Compared to the introductory example the possibility to restrict or to maximize native contributions became available because column NC
was added to data frame Cattle
. Additionally, the possibility to minimize or to restrict the kinship at native segments sKinatN
became available since this kinship was used as an argument to function candes. The values for the current generation are
cand$mean
## BV NC sKin sKinatN
## 1 0.0393541 0.3850859 0.05701273 0.06713845
Function opticont can now be used to perform the optimization.
Depending on what the objective of the breeding program is, you may continue reading at the appropriate section:
First we create a list of constraints:
con <- list(uniform="female")
con$ub.sKin <- cand$mean$sKin + (1-cand$mean$sKin)*(1/(2*Ne))
Again, equal contributions are assumed for the females and only the contributions of males are to be optimized. The upper bound for the mean segment based kinship was derived from the effective population size as explained above. Now the optimum contributions of the selection candidates can be calculated:
Offspring <- opticont("max.BV", cand, con, trace=FALSE)
Offspring$info
## valid solver status
## 1 TRUE cccp2 optimal
The expected values of the parameters in the next generation are
Offspring$mean
## BV NC sKin sKinatN
## 1 1.022091 0.3624048 0.06172791 0.0829775
The results are the same as in the introductory example (as expected). This approach may be apppropriate for a population without introgression, but for populations with historic introgression, the kinship at native alleles should be restricted as well in accordance with the desired effective size, and the native contributions should be restricted in order not to decrease. Otherwise the genetic originality of the breed may get lost in the long term.
con$ub.sKinatN <- cand$mean$sKinatN +(1-cand$mean$sKinatN)*(1/(2*Ne))
con$lb.NC <- cand$mean$NC
Offspring2 <- opticont("max.BV", cand, con)
For comparison, the summaries of both scenarios are combined into a single data frame:
rbind(Ref=cand$mean, maxBV=Offspring$mean, maxBV2=Offspring2$mean)
## BV NC sKin sKinatN
## Ref 0.0393541 0.3850859 0.05701273 0.06713845
## maxBV 1.0220909 0.3624048 0.06172791 0.08297750
## maxBV2 0.8997310 0.3850860 0.05933899 0.07180402
Since native contributions and breeding values are negatively correlated, the genetic gain decreases slightly when native contributions are constrained not to decrease.
Minimizing inbreeding means to minimize the average kinship of the population in order to enable breeders to avoid inbreeding. This is the appropriate approach e.g. for companion animals suffering from a historic bottleneck. It can be done with or without accounting for breeding values. In the example below no breeding values are considered since accurate breeding values are not available for most of these breeds.
First we create a list of constraints:
con <- list(uniform="female")
Again, equal contributions are assumed for the females and only the contributions of males are to be optimized. The segment based kinship is not constrained in this example because it should be minimized.
Offspring <- opticont("min.sKin", cand, con)
Offspring$mean
## BV NC sKin sKinatN
## 1 -0.3326131 0.4555244 0.04311883 0.05692836
Minimizing kinship without constraining the mean breeding value decreases the mean breeding value in the offspring slightly because the individuals with high breeding values are related. For this breed, it also increases the native contribution because individuals from other breeds were related.
While in livestock breeds the native contributions should be restricted in order to maintain the genetic originality of the breeds, in several companion breeds the opposite is true. Several companion breeds have high inbreeding coefficients and descend from only very few (e.g. 3) founders (Wellmann and Pfeiffer 2009), and purging seems to be not feasible. Hence, a sufficient genetic diversity of the population cannot be achieved in the population even if marker data is used to minimize inbreeding. For these breeds it may be appropriate to use unrelated individuals from a variety of other breeds in order to increase the genetic diversity. However, only a small contribution from other breeds is needed, so the native contributions should be restricted also for these breeds in order to preserve their genetic originality. Hence, the difference between a breed with high diversity and a breed with low diversity suffering from inbreeding depression is, that the optimum value for the native contribution is smaller than 1 for the latter.
For such a breed it is advisable to allow the use of individuals from other breeds but to restrict the admissible mean contribution from other breeds in the population. The mean kinship at native alleles should be restricted as well to require only a small amount of introgression:
con$lb.NC <- 0.50
con$ub.sKinatN <- cand$mean$sKinatN +(1-cand$mean$sKinatN)*(1/(2*Ne))
Offspring2 <- opticont("min.sKin", cand, con)
For comparison, the estimates for both scenarios are combined into a single data frame:
rbind(Ref=cand$mean, minKin=Offspring$mean, minKin2=Offspring2$mean)
## BV NC sKin sKinatN
## Ref 0.0393541 0.3850859 0.05701273 0.06713845
## minKin -0.3326131 0.4555244 0.04311883 0.05692836
## minKin2 -0.5030629 0.5000001 0.04561306 0.06570513
For endangered breeds the priority of a breeding program could be to recover the original genetic background by maximizing native contributions. However, since the individuals with highest native contributions are related, this may considerably increase the inbreeding coefficients if the diversity at native alleles is not preserved. Hence, constraints are defined below not only for the segment based kinship but also for the kinship at native segments in accordance with the desired effective size:
con <- list(uniform="female")
con$ub.sKin <- cand$mean$sKin + (1-cand$mean$sKin )*(1/(2*Ne))
con$ub.sKinatN <- cand$mean$sKinatN + (1-cand$mean$sKinatN)*(1/(2*Ne))
Offspring <- opticont("max.NC", cand, con)
Offspring$info
## valid solver status
## 1 TRUE cccp2 optimal
Offspring$mean
## BV NC sKin sKinatN
## 1 -0.5493285 0.5174496 0.04998906 0.07180366
For this breed, maximizing native contributions results in negative genetic gain because native contributions and breeding values are negatively correlated. This can be avoided by adding an additional constraint for the breeding values:
con$lb.BV <- cand$mean$BV
Offspring2 <- opticont("max.NC", cand, con)
For comparison, the estimated parameters of both scenarios are combined into a single data frame:
rbind(Ref=cand$mean, maxNC=Offspring$mean, maxNC2=Offspring2$mean)
## BV NC sKin sKinatN
## Ref 0.03935410 0.3850859 0.05701273 0.06713845
## maxNC -0.54932855 0.5174496 0.04998906 0.07180366
## maxNC2 0.03935842 0.4980640 0.05007611 0.07180818
While removing introgressed genetic material from the population is one possibility to increase the conservation value of an endangered breed, an alternative approach is to increase the genetic distance between the endangered breed and commercial breeds. In this case we do not care about whether alleles are native or not. We just want to accumulate haplotype segments which are rare in commercial breeds. This can be done with a core set approach.
In the core set approach, a hypothetical population is considered, consisting of individuals from various breeds. This population is called the core set. The contributions of each breed to the core set are such that the genetic diversity of the core set is maximized.
In the following example the parameter to be minimized is the mean kinship of individuals from the core set in the next generation. Constraint uniform
defined below states that the contributions of the male selection candidates from the breed of interest are to be optimized, whereas individuals from all other breeds have uniform contributions.
Since the average kinship in a multi-breed population should be managed, argument phen
of function cand contains individuals from all genotyped breeds. This was not the case in the above examples, where argument phen
contained only the selection candidates.
cand <- candes(phen=Cattle, sKin=sKin, sKinatN.Angler=sKinatN, bc="sKin")
##
## Mean values of the parameters are: Value
## for trait 'BV' in Angler : 0.0394
## for trait 'NC' in Angler : 0.3851
## for kinship 'sKin' across breeds: 0.0344
## for nat. kin. 'sKinatN.Angler' in Angler : 0.0668
## for kinship 'sKin.Angler' in Angler : 0.0569
## for kinship 'sKin.Holstein' in Holstein : 0.1113
## for kinship 'sKin.Fleckvieh' in Fleckvieh : 0.0729
## for kinship 'sKin.Rotbunt' in Rotbunt : 0.1103
##
## Available objective functions and constraints:
## for trait 'BV' in Angler : min.BV, max.BV, lb.BV, eq.BV, ub.BV
## for trait 'NC' in Angler : min.NC, max.NC, lb.NC, eq.NC, ub.NC
## for kinship 'sKin' across breeds: min.sKin, ub.sKin
## for nat. kin. 'sKinatN.Angler' in Angler : min.sKinatN.Angler, ub.sKinatN.Angler
## for kinship 'sKin.Angler' in Angler : min.sKin.Angler, ub.sKin.Angler
## for kinship 'sKin.Holstein' in Holstein : min.sKin.Holstein, ub.sKin.Holstein
## for kinship 'sKin.Fleckvieh' in Fleckvieh : min.sKin.Fleckvieh, ub.sKin.Fleckvieh
## for kinship 'sKin.Rotbunt' in Rotbunt : min.sKin.Rotbunt, ub.sKin.Rotbunt
##
## ub lb uniform
Unif <- c("Angler.female", "Fleckvieh", "Holstein", "Rotbunt")
mKin <- cand$mean$sKinatN.Angler
con <- list(uniform = Unif, ub.sKinatN.Angler = mKin + (1-mKin)*(1/(2*Ne)))
The upper bound for the mean native kinship was derived from the effective population size as explained above. Now the optimum contributions of the selection candidates can be calculated:
Offspring <- opticont("min.sKin", cand, con, trace=FALSE)
##
## Using solver 'cccp' with parameters:
## Value
## trace 0
## abstol 1e-05
## feastol 1e-05
## stepadj 0.9
## maxiters 100
## reltol 1e-06
## beta 0.5
##
## A square matrix was approximated by a positive
## definite matrix with relative distance 5e-04.
## valid solver status
## TRUE cccp optimal
##
## Variable Value Bound OK?
## ---------------------------------------------------------
## sKin across breeds 0.0301 min :
## ---------------------------------------------------------
## lower bounds all x >= lb : TRUE
## upper bounds all x <= ub : TRUE
## breed contribution Angler 0.4791 == 0.4791 : TRUE
## breed contribution Fleckvieh 0.4243 == 0.4243 : TRUE
## breed contribution Holstein 0.0443 == 0.0443 : TRUE
## breed contribution Rotbunt 0.0523 == 0.0523 : TRUE
## sex contrib. diff. Angler 0 == 0 : TRUE
## sex contrib. diff. Fleckvieh 0 == 0 : TRUE
## sex contrib. diff. Holstein 0 == 0 : TRUE
## sex contrib. diff. Rotbunt 0 == 0 : TRUE
## BV Angler -0.2733 :
## NC Angler 0.464 :
## sKin across breeds 0.0301 :
## sKin Angler 0.0439 :
## sKin Holstein 0.1122 :
## sKin Fleckvieh 0.0738 :
## sKin Rotbunt 0.1112 :
## sKinatN Angler 0.0597 <= 0.0715 : TRUE
## ---------------------------------------------------------
Offspring$info
## valid solver status
## 1 TRUE cccp optimal
Offspring$mean
## BV NC sKin sKin.Angler sKin.Holstein sKin.Fleckvieh
## 1 -0.2732721 0.4639502 0.03014074 0.04389072 0.1121748 0.07380259
## sKin.Rotbunt sKinatN.Angler
## 1 0.1111811 0.05973452
Since the contributions of the selection candidates minimize the mean kinship sKin
in the core set, they maximize the genetic diversity of the core set. This is achieved by increasing the gentic diversity within the breed or by increasing the genetic distance between the breed of interest and the other breeds. The optimum contributions are standardized so that their sum is equal to one within each breed:
head(Offspring$parent[,c("Breed","lb","oc","ub")])
## Breed lb oc ub
## 276000101676415 Angler 0.000000000 4.246192e-06 0.500000000
## 276000108612636 Angler 0.004032258 4.032258e-03 0.004032258
## 276000102372349 Angler 0.004032258 4.032258e-03 0.004032258
## 276000102379430 Angler 0.000000000 5.262331e-06 0.500000000
## 276000108826036 Angler 0.000000000 1.388361e-06 0.500000000
## 276000111902076 Angler 0.000000000 1.240655e-06 0.500000000
All evaluations using pedigree data are demonstrated at the example of the Hinterwald cattle. A pedigree is contained in the package. The pedigree and the functions dealing with pedigree data have already been described in the companion vignette for basic pedigree-based evaluations.
The pedigree completeness is an important factor to get reliable results. If an animal has many missing ancestors, then it would falsely considered to be unrelated to other animals, so it will falsely obtain high optimum contributions. There are several approaches to overcome this problem:
Calculate the pedigree completeness for all selection candidates and exclude individuals with a small number of equivalent complete generations from the evaluations. The number of equivalent complete generations can be computed with function summary.
Classify the breed of founders born after some fixed date as unknown
, and restrict the genetic contribution from these founders in the offspring. The breed names of the founders can be classified by using appropriate values for parameters lastNative
and thisBreed
in function prePed.
Classify the breed of founders born after some fixed date as unknown
, so that these founders are considered non-native, and restrict or minimize the kinship at native alleles which is less affected by incomplete pedigrees than the classical pedigree-based kinship.
Of course, all 3 approaches can be followed simultaneously. First, we prepare the pedigree and classify the breed of founders born after 1970 to be unknown
:
data("PedigWithErrors")
Pedig <- prePed(PedigWithErrors, thisBreed="Hinterwaelder", lastNative=1970)
head(Pedig[,-1])
## Sire Dam Sex Breed Born I Offspring
## S276000890888469 <NA> <NA> male unknown NA NA TRUE
## S276000891160479 <NA> <NA> male unknown NA NA TRUE
## S276000811209491 <NA> <NA> male unknown NA NA TRUE
## S276000811063904 <NA> <NA> male unknown NA NA TRUE
## S276000892147965 <NA> <NA> male unknown NA NA TRUE
## S276000891895524 <NA> <NA> male unknown NA NA TRUE
The breed composition of individuals can be estimated with function pedBreedComp. Since the native contribution should be considered in some scenarios, they are added as additional column NC
to the pedigree.
cont <- pedBreedComp(Pedig, thisBreed="Hinterwaelder")
Pedig$NC <- cont$native
tail(cont[, 2:5])
## native unknown unbek0 Fleckvieh
## 276000813677673 0.48454285 0.2441406 0.029510498 0.09605408
## 276000812771580 0.31429291 0.5390625 0.020900726 0.06287766
## 276000892197676 0.37435150 0.4394531 0.023830414 0.06507492
## 276000813517568 0.50592804 0.1152344 0.032798767 0.08444214
## 276000813752879 0.58937836 0.1464844 0.035198212 0.10577011
## 276000891978029 0.08495712 0.8837891 0.004339218 0.01391411
We choose the individuals included in data.frame Phen
as selection candidates if their number of equivalent complete generations is at least 3.0. These are the individuals contained in vector keep
defined below. In a real application the individuals would be used as selection candidates that could become parents of the forthcomming birth cohorts.
data("Phen")
Summary <- summary(Pedig, keep=Pedig$Indiv %in% Phen$Indiv)
keep <- Summary$Indiv[Summary$equiGen>=3.0]
table(Pedig[keep, "Sex"])
##
## female male
## 47 98
Below, the columns from the pedigree are added to data frame Phen
, which now contains the individual IDs in Colmumn 1 (Indiv
), sexes in Column 2 (Sex
), breed names (Breed
), years of birth (Born
), breeding values (BV
), and the native contributions (NC
) of the phenotyped individuals.
Phen <- merge(Pedig, Phen[,c("Indiv", "BV")], by="Indiv")
Phen <- Phen[Phen$Indiv %in% keep, c("Indiv", "Sex","Breed", "Born", "BV", "NC")]
head(Phen)
## Indiv Sex Breed Born BV NC
## 1 276000810958027 male Hinterwaelder 2003 1.2899084 0.3742676
## 2 276000811082118 male Hinterwaelder 2003 -1.7290435 0.4705811
## 3 276000811287745 female Hinterwaelder 2001 -1.6108588 0.5804138
## 4 276000811597070 male Hinterwaelder 2001 0.6909200 0.3008118
## 5 276000811597110 male Hinterwaelder 2003 -0.2940523 0.5612488
## 6 276000811597136 female Hinterwaelder 2002 1.2560016 0.2345886
The breeding values were simulated such that breeding values and native contributions are negatively correlated. This mimics historic introgression from a high-yielding commercial breed.
A matrix containing the pedigree based kinship between all pairs of individuals can be computed with function pedIBD. It is half the additive relationship matrix. The pedigree based kinship at native alleles can be calculated from the results of function pedIBDatN.
The data fame containing phenotypes and the kinships are combined below into a single R-object with function candes. This function computes also the current values of the parameters and displays the available objective functions and constraints. Below, the pedigree based kinship is named pKin
, and the kinship at native alleles is named pKinatN
:
phen <- Phen[Phen$Indiv %in% keep, ]
pKin <- pedIBD(Pedig, keep.only=keep)
pKinatN <- pedIBDatN(Pedig, thisBreed="Hinterwaelder", keep.only=keep)
cand <- candes(phen = phen, pKin = pKin, pKinatN = pKinatN)
##
## Mean values of the parameters are: Value
## for trait 'BV' in Hinterwaelder: -0.3960
## for trait 'NC' in Hinterwaelder: 0.5293
## for kinship 'pKin' in Hinterwaelder: 0.0327
## for nat. kin. 'pKinatN' in Hinterwaelder: 0.0736
##
## Available objective functions and constraints:
## for trait 'BV' in Hinterwaelder: min.BV, max.BV, lb.BV, eq.BV, ub.BV
## for trait 'NC' in Hinterwaelder: min.NC, max.NC, lb.NC, eq.NC, ub.NC
## for kinship 'pKin' in Hinterwaelder: min.pKin, ub.pKin
## for nat. kin. 'pKinatN' in Hinterwaelder: min.pKinatN, ub.pKinatN
##
## ub lb uniform
Compared to the introductory example the possibility to restrict or to maximize native contributions becomes available because column NC
is now included in data frame Phen
. Additionally, there is the possibility to minimize or to restrict the kinship at native alleles pKinatN
and the pedigree based kinship pKin
.
For defining appropriate threshold values for the constraints, the mean kinships, the mean native contribution, and the mean breeding value in the current generation need to be known. The values can be obtained as
cand$mean
## BV NC pKin pKinatN
## 1 -0.3960072 0.5292555 0.0327059 0.07362899
Depending on what the objective of the breeding program is, you may continue reading at the appropriate section:
This is the traditional approach proposed by T. H. E. Meuwissen (1997). First we create a list of constraints:
con <- list(uniform="female")
con$ub.pKin <- cand$mean$pKin + (1-cand$mean$pKin)*(1/(2*Ne))
Here, equal contributions are assumed for the females and only the contributions of males are to be optimized. The upper bound for the mean pedigree based kinship was derived from the effective population size as explained above. Now the optimum contributions of the selection candidates can be calculated:
Offspring <- opticont("max.BV", cand, con)
Offspring$mean
## BV NC pKin pKinatN
## 1 0.3763356 0.4586418 0.03754276 0.09342713
This approach may be apppropriate for a population without introgression and complete pedigrees, but for populations with historic introgression, the kinship at native alleles should be restricted as well in accordance with the desired effective size, and the native contributions should be restricted in order not to decrease. Otherwise the genetic originality of the breed may get lost in the long term.
con$ub.pKinatN <- cand$mean$pKinatN +(1-cand$mean$pKinatN)*(1/(2*Ne))
con$lb.NC <- cand$mean$NC
Offspring2 <- opticont("max.BV", cand, con)
For comparison, the parameters of both scenarios are combined into a single data frame with rbind
:
rbind(Ref=cand$mean, maxBV=Offspring$mean, maxBV2=Offspring2$mean)
## BV NC pKin pKinatN
## Ref -0.3960072 0.5292555 0.03270590 0.07362899
## maxBV 0.3763356 0.4586418 0.03754276 0.09342713
## maxBV2 0.1644203 0.5292556 0.03618460 0.07826114
Thus, genetic gain in Method 2 is only slightly below the genetic gain in Method 1, but the native contributions do not decrease and the kinship at native alleles increases at a lower rate.
Minimizing inbreeding means to minimize the average kinship of the population in order to enable breeders to avoid inbreeding. This is the appropriate approach e.g. for companion animals suffering from a historic bottleneck. It can be done with or without accounting for breeding values. In the example below no breeding values are considered since accurate breeding values are not available for most of these breeds.
First we create a list of constraints:
con <- list(uniform="female")
Again, equal contributions are assumed for the females and only the contributions of males are to be optimized. The pedigree based kinship is not constrained in this example because it should be minimized.
Offspring <- opticont("min.pKin", cand, con)
Offspring$mean
## BV NC pKin pKinatN
## 1 -0.1346211 0.4705057 0.02793028 0.07369155
The approach shown above has the disadvantage that kinships between individuals are less reliable if ancestors are missing in the pedigree. The alternative approach, shown below, is to minimize the kinship at native alleles and to restrict pedigree based kinship.
While in livestock breeds the native contributions should be preserved in order to maintain the genetic originality of the breeds, in several companion breeds the opposite is true. Several companion breeds have high inbreeding coefficients and descend from only very few (e.g. 3) founders. Hence, a sufficient genetic diversity cannot be achieved in the population. For these breeds it may be appropriate to use unrelated individuals from a variety of other breeds in order to increase the genetic diversity. However, only a small contribution from other breeds is needed, so the native contributions should be restricted also for these breeds in order to preserve their genetic originality. The difference between a breed with high diversity and a breed with low diversity suffering from inbreeding depression is, that the optimum value for the native contribution is smaller than 1 for the latter. For such a breed it is advisable to allow the use of individuals from other breeds but to restrict the admissible mean contribution from other breeds.
In summary, the alternative approach is to minimize the kinship at native alleles and to restrict pedigree based kinship and native contributions:
con <- list(uniform="female")
con$lb.NC <- 1.05*cand$mean$NC
con$ub.pKin <- cand$mean$pKin + (1-cand$mean$pKin)*(1/(2*Ne))
Offspring2 <- opticont("min.pKinatN", cand, con)
For comparison, the parameter estimates are combined into a single data frame:
rbind(Ref=cand$mean, minKin=Offspring$mean, minKin2=Offspring2$mean)
## BV NC pKin pKinatN
## Ref -0.3960072 0.5292555 0.03270590 0.07362899
## minKin -0.1346211 0.4705057 0.02793028 0.07369155
## minKin2 -0.4329621 0.5557183 0.03325358 0.06910438
The pedigree based kinship is slightly higher in the second approach, but the kinship at native alleles is lower. Since pedigree based kinships are less reliable due to missing ancestors in the pedigree, the second approach is recommended. However, the use of pedigree data has the disadvantage that only the expected kinships can be minimized. The expected kinships deviate from the realized kinships due to mendelian segregation. Hence, for breeds with serious inbreeding problems it is recommended to genotype the selection candidates and to perform marker-based optimum contribution selection.
For endangered breeds the priority of a breeding program could be to recover the original genetic background by maximizing native contributions. However, since the individuals with highest native contributions are related, this may considerably increase the inbreeding coefficients if the diversity at native alleles is not preserved. Hence, constraints are defined below not only for the pedigree based kinship, but also for the kinship at native alleles in accordance with the desired effective size:
con <- list(uniform="female")
con$ub.pKin <- cand$mean$pKin + (1-cand$mean$pKin )*(1/(2*Ne))
con$ub.pKinatN <- cand$mean$pKinatN + (1-cand$mean$pKinatN)*(1/(2*Ne))
Offspring <- opticont("max.NC", cand, con)
Offspring$mean
## BV NC pKin pKinatN
## 1 -0.5932771 0.5848983 0.03754245 0.07393027
For some breeds, native contributions and breeding values are negatively correlated, so maximizing native contributions results in negative genetic. This can be avoided by adding an additional constraint for the breeding values:
con$lb.BV <- cand$mean$BV
Offspring2 <- opticont("max.NC", cand, con)
For comparison, the estimates for both scenarios are combined into a single data frame:
rbind(Ref=cand$mean, maxNC=Offspring$mean, maxNC2=Offspring2$mean)
## BV NC pKin pKinatN
## Ref -0.3960072 0.5292555 0.03270590 0.07362899
## maxNC -0.5932771 0.5848983 0.03754245 0.07393027
## maxNC2 -0.3960031 0.5820190 0.03754367 0.07467643
Meuwissen, T H E. 2009. “Genetic Management of Small Populations: A Review.” Acta Agriculturae Scand Section A 59: 71–79.
Meuwissen, T. H. E. 1997. “Maximising the Response of Selection with a Predefined Rate of Inbreeding.” J. Animal Sci 75: 934–40.
Wellmann, R., and I. Pfeiffer. 2009. “Pedigree Analysis for Conservation of Genetic Diversity and Purging.” Genetical Research (Camb) 91 (34).