orderPed | R Documentation |
Orders a pedigree so parents come before offspring
orderPed(ped, time_born=NULL)
ped |
pedigree with id, dam and sire in ech column |
time_born |
an optional vector of birth dates by which the pedigree can be ordered) |
an ordered pedigree pedigree with id, dam and sire in each column
This function has changed name from order.ped
in earler versions <2.42. order.ped
did not always (rarely) ordered the pedigree correctly. This new function uses the kindepth
function from the kinship2
package
Jarrod Hadfield j.hadfield@ed.ac.uk
MCMCped
## Not run: pedigree<-matrix(NA, 8,3) pedigree[,1]<-1:8 pedigree[,2][5:8]<-c(1,1,2,2) pedigree[,3][5:8]<-c(3,3,4,4) pedigree<-pedigree[sample(1:8),] pedigree2<-orderPed(pedigree) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.