magnusdv / forrel

Forensic pedigree analysis and relatedness inference
GNU General Public License v2.0
10 stars 0 forks source link

`readFam` and twins #34

Closed thoree closed 4 years ago

thoree commented 4 years ago

In Windows Familas one can check if profiles from tvilling1 and tvilling2 are identical by entering a parent child relationship and overule by ticking 'Direct/identity' (!). If the genotypes are identical, the likelihood is for one of them. With a mutation model, the likelihood returned is 0. readFam runs into problems:

library(forrel)
#> Loading required package: pedtools
readFam("http://familias.name/mz.fam")
#> Familias version: 3.2.8
#> Read DVI: No
#> 
#> Number of individuals (excluding 'extras'): 2
#>   Individual 'tvilling1': Genotypes for 2 markers read
#>   Individual 'tvilling2': Genotypes for 2 markers read
#> 
#> Number of pedigrees: 1
#> Warning in readFam("http://familias.name/mz.fam"): NAs introduced by coercion
#> Error in if (sex[par.idx] == 1) fidx.i[child.idx] = par.idx else midx.i[child.idx] = par.idx: missing value where TRUE/FALSE needed

Created on 2020-02-21 by the reprex package (v0.3.0)

magnusdv commented 4 years ago

Twins are not supported yet. For now readFam() raises an error if it detects the "Direct" keyword.