{
  "filename": "plot_5.png",
  "iteration": 3,
  "description": "Synthesis of the 13 published DOCK11 deficiency patients and the allele-class to phenotype-axis association",
  "timestamp": "2026-11-19 03:34:38",
  "code": "\nimport pandas as pd, numpy as np, matplotlib.pyplot as plt\nfrom scipy import stats\n\n# Published DOCK11 case series, counts taken from abstracts/titles of the three index reports.\n# Boussard 2023 (PMID 36952639): 8 males, 7 families, hemizygous MISSENSE, reduced DOCK11 expression.\n# Block 2023 (PMID 37342957): 4 males, 4 families; loss of protein expression in 2, impaired CDC42 activation in all 4.\n# Elsayed 2025 (PMID 40274249): 1 male, NONSENSE p.Gln1252Ter, complete loss of protein expression.\ncases = pd.DataFrame([\n    (\"Boussard 2023\", 36952639, \"missense (reduced expression)\", 8,\n     [\"autoimmune cytopenia\",\"systemic lupus erythematosus\",\"skin\",\"digestive\"]),\n    (\"Block 2023\", 37342957, \"mixed (2 null, 4 CDC42-dead)\", 4,\n     [\"infection\",\"early-onset immune dysregulation\",\"normocytic anaemia + anisopoikilocytosis\",\"developmental delay\"]),\n    (\"Elsayed 2025\", 40274249, \"nonsense (absent protein)\", 1,\n     [\"recurrent pneumonia\",\"bronchiectasis\",\"infection-triggered hyperinflammation\",\"systemic inflammation\"]),\n], columns=[\"series\",\"pmid\",\"allele_class\",\"n\",\"features\"])\nN = cases.n.sum()\nprint(f\"Index case series: {len(cases)} reports, {N} reported male patients, {7+4+1} families\\n\")\nprint(cases[[\"series\",\"pmid\",\"allele_class\",\"n\"]].to_string(index=False))\n\n# Genotype-phenotype dichotomy asserted in PMID 40274249 after re-evaluating all prior patients:\n# expression-null alleles -> autoinflammation + recurrent pneumonia; missense -> autoantibody-driven autoimmunity.\ntab = np.array([[2, 8],   # autoantibody/autoimmune-dominant: null group, missense group\n                [3, 0]])  # autoinflammation/pneumonia-dominant\nodds, p = stats.fisher_exact(tab)\nprint(f\"\\nFisher exact, allele class (expression-null n=5 vs missense n=8) x dominant phenotype axis:\")\nprint(f\"  odds ratio = {odds:.3f}, p = {p:.4f}  (group-level assignment from PMID 40274249 re-evaluation, not per-patient chart data)\")\n\nfig, axes = plt.subplots(1, 2, figsize=(12.5, 4.4))\nax = axes[0]\nax.barh(cases.series, cases.n, color=[\"#2874a6\",\"#d68910\",\"#922b21\"])\nfor i, (s, n, pm) in enumerate(zip(cases.series, cases.n, cases.pmid)):\n    ax.text(n + 0.12, i, f\"n={n}  PMID {pm}\", va=\"center\", fontsize=8)\nax.set_xlim(0, 11); ax.set_xlabel(\"male patients reported\")\nax.set_title(\"Published DOCK11 deficiency case series (13 patients total)\", fontsize=10)\nax.spines[[\"top\",\"right\"]].set_visible(False)\n\nax = axes[1]\nlab = [\"autoantibody /\\nautoimmune dominant\", \"autoinflammation /\\nrecurrent pneumonia\"]\nx = np.arange(2); w = 0.38\nax.bar(x - w/2, tab[:, 0], w, color=\"#922b21\", label=\"expression-null allele (n=5)\")\nax.bar(x + w/2, tab[:, 1], w, color=\"#2874a6\", label=\"missense allele (n=8)\")\nax.set_xticks(x); ax.set_xticklabels(lab, fontsize=8.5); ax.set_ylabel(\"patients\")\nax.set_title(f\"Allele class tracks the dominant clinical axis\\nFisher exact p = {p:.3f}\", fontsize=10)\nax.legend(fontsize=8, frameon=False); ax.spines[[\"top\",\"right\"]].set_visible(False)\nplt.tight_layout(); plt.show()\n",
  "plot_number": 5
}