about summary refs log tree commit diff
path: root/test/python/test_openapi.py
diff options
context:
space:
mode:
authorPjotr <wrk@bosa.lan>2026-11-10 23:08:31 +0000
committerPjotr <wrk@bosa.lan>2026-11-10 23:08:31 +0000
commitb4246412072773819f4500cb008f71c3f3101fdf (patch)
treed953ed61c7ca9dfad87483b0e0e311d79505e71f /test/python/test_openapi.py
parente2386cdf37196f7571afda4cfb9d1ec70b194cf7 (diff)
downloadgenenetwork4-b4246412072773819f4500cb008f71c3f3101fdf.tar.gz
qtl2: name the genotype model, and say what the conversion dropped
Two engines reading one riset panel can fit different predictors, and the
reply now says which one it used and what it cost -- with this panel's own
numbers.

  * `genotype_model: "riself" | "f2"` on /compute/qtl2 (`het` kept as the
    older spelling: drop/keep). riself is the default: R/qtl's
    convert2riself coding, the H calls become missing and the HMM
    re-imputes them. f2 keeps them as a third genotype -- a diagnostic.
  * The conversion now counts the calls it drops and keeps the count
    beside the cross (conversion.json), so a reply can say
    "610684 heterozygous call(s) (12.7 %) were dropped". A cross
    converted before that file existed measures the count once, on first
    use, rather than never.
  * Crossed with the note that already explained the H drop, so the two
    read together: what riself does, how many calls it cost, and what f2
    would give.

Documented in the README as "Why R/qtl and R/qtl2 disagree on a riset
panel", with the measurements (BXD trait 16627, BXD.8: R/qtl 9.59 at
rs33299937; qtl2 riself 3.73; qtl2 f2 9.68), R/qtl's adaptive
convert2riself rule quoted from its own source, and qtl2's side: riself
has two states, f2 three, and `genril2` -- from qtl2 0.18, "the progeny
are inbred lines", cross_info first column the number of generations --
is the honest model for residual heterozygosity and is available in the
0.42 we run. What is missing for it is recorded precisely: a founder-based
cross expects individual genotypes coded as founder alleles rather than
1/2/3 (a prototype with numeric codes read every genotype as missing), so
founder_geno from the two parental alleles and an allele-coded het remain
to be done, with DOL as the counter-example (its H is a collapsed DO, not
residual heterozygosity).

tests/qtl2.rs: the model is reported (Cross: riself / Cross: f2), the
dropped count is in the reply, keeping the calls finds more, and an
unknown model is refused rather than ignored.
Diffstat (limited to 'test/python/test_openapi.py')
0 files changed, 0 insertions, 0 deletions