Learn R Programming

GENLIB (version 1.0.3)

gen.occ: Ancestor occurences

Description

Returns the number of times that the specified ancestors are present in the genalogies of the specified probands.

Usage

gen.occ( gen, pro = "0", ancestors = "0", typeOcc = "IND", ...)

Arguments

Value

A matrix with number of lines equal to the number of ancestors included and the number of columns equal to the number of probands included if typeOcc="BRUT" or only one column if typeOcc="TOTAL"

See Also

gen.genealogy gen.rec gen.implex gen.meangendepth gen.gc

Examples

Run this code
data(geneaJi) 
genJi<-gen.genealogy(geneaJi) 
Number of occurences of ancestors in the specified proband's genealogy
gen.occ(genJi, pro=c(1,29), ancestors=c(3,6,10,12,14,16,18,20,26,28))

data(genea140) 
gen140<-gen.genealogy(genea140) 
gen.occ(gen140, pro=c(454422,676521,677273,717537,717634,717709,868572), 
        ancestors=c(18305,18528,31114,18325))

Run the code above in your browser using DataLab