powered by
For every individual in the pedigree, it will assign them their maternal (or paternal) value for an observed variable of interest.
ped_maternal(ped, value_from, name_to, use_dam = TRUE, set_na = NULL)
The input dataframe, plus an additional column with maternal (or paternal) values of a variable of interest.
A dataframe containing the pedigree. Individual (id), maternal (dam), and paternal (sire) identities are mandatory columns.
Name of the column of interest.
A string naming the new output column.
Extract maternal values. If false, parental values are returned.
When maternal values are unknown, NA values are generated by default. This option allows to set a different value.
# To assign maternal inbreeding as a new variable, we can do as follows: data(dama) dama <- ip_F(dama) dama <- ped_maternal(dama, value_from = "Fi", name_to = "Fdam") tail(dama)
Run the code above in your browser using DataLab