R: Minimum genetic distance between two individuals

gen.findDistance {GENLIB} | R Documentation

## Minimum genetic distance between two individuals

### Description

Returns the minimum distance (number of meioses) between the specified individuals through one specified ancestor.

### Usage

    gen.findDistance(gen, individuals, ancestor)

### Arguments

`gen` | An object of class GLgen obtained with gen.genealogy, gen.lineages or gen.branching. Required.
`individuals` | A vector of individual id numbers between which to calculate the distance. Required.
`ancestor` | A common ancestor to the specified individuals. Required.

### Value

returns a numeric value

### See Also

`gen.genealogy` `gen.founder` `gen.findMRCA` `gen.findFounders` `gen.find.Min.Distance.MRCA`

### Examples

    data(geneaJi)
    genJi<-gen.genealogy(geneaJi)
    gen.findDistance(genJi, individuals=c(1,29), ancestor=17)
    gen.findDistance(genJi, individuals=c(1,29), ancestor=26)

    data(genea140)
    gen140<-gen.genealogy(genea140)
    gen.findDistance(gen140, individuals=c(409033,408728), ancestor=38714)
    gen.findDistance(gen140, individuals=c(408728,408828), ancestor=95080)

[Package GENLIB version 1.1.5 Index]