Description Usage Arguments Details Value Examples
Return incidence and structure for a additive_genetic_competition
model, given the pedigree, the spatial coordinates and codes of the
observations and the competition decay parameter.
1 | additive_genetic_competition(pedigree, coordinates, id, decay, autofill = TRUE)
|
pedigree |
object of class 'pedigree' |
coordinates |
two-column matrix-like set of row and column coordinates of observational units |
id |
integer vector of numeric codes for observed individuals |
decay |
numeric. The positive value of the decay parameter α. Typically 1 or 2. See Details. |
autofill |
logical. If TRUE (default) it will try to fill missing rows or columns with missing observations. Otherwise, will treat individuals as neighbours even if they are across an empty line. |
id
must hold the codes of observed individuals in the original
codification. If recoding took place when building the pedigree, this
function will handle the codes internally.
A list with elements pedigree
, incidence.matrix
,
structure.matrix
and structure.type
, which is a string
indicating either covariance
or precision
.
1 2 3 4 5 6 7 | dat <- data.frame(id = 1:5,
sire = c(11, 11, 2, 3, 2),
dam = c(12, NA, 1, 12, 1),
x = c(rep(1:2, times = 2), 3),
y = c(rep(1:2, each = 2), 3))
ped <- build_pedigree(1:3, data = dat)
breedR:::additive_genetic_competition(ped, coord = dat[, c('x', 'y')], dat$id, 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.