{
  "filename": "plot_6.png",
  "iteration": 2,
  "description": "Uroc1 knockout mouse phenotype breadth and cross-species orthologs",
  "timestamp": "2026-11-20 14:31:34",
  "code": "\nimport requests, json, pandas as pd, numpy as np, matplotlib.pyplot as plt\nH={\"Accept\":\"application/json\",\"User-Agent\":\"Mozilla/5.0\"}\n\nr=requests.get(\"https://www.ebi.ac.uk/mi/impc/solr/statistical-result/select\",\n   params={\"q\":\"marker_symbol:Uroc1\",\"wt\":\"json\",\"rows\":2000,\n           \"fl\":\"procedure_name,parameter_name,zygosity,p_value,significant,mp_term_name\"},\n   headers=H,timeout=90).json()[\"response\"][\"docs\"]\nsr=pd.DataFrame(r)\nsr[\"significant\"]=sr[\"significant\"].astype(bool)\nsumm=sr.groupby(\"procedure_name\").agg(tests=(\"parameter_name\",\"size\"), sig=(\"significant\",\"sum\")).sort_values(\"tests\",ascending=False)\nprint(summ.to_string())\nprint(\"\\nSignificant hits:\")\nprint(sr[sr.significant][[\"procedure_name\",\"parameter_name\",\"mp_term_name\",\"p_value\"]].to_string(index=False))\n\n# behavioural / neurological procedures specifically\nneuro=[\"Open Field\",\"Combined SHIRPA and Dysmorphology\",\"Grip Strength\",\n       \"Acoustic Startle and Pre-pulse Inhibition (PPI)\",\"Light-Dark Test\"]\nnb=sr[sr.procedure_name.isin(neuro)]\nprint(\"\\nNeurobehavioural parameters tested: %d, significant: %d\"%(len(nb), nb.significant.sum()))\n\nfig,ax=plt.subplots(figsize=(9.5,6))\ns=summ.iloc[::-1]\nax.barh(s.index, s.tests, color=\"#5b6b7c\", label=\"parameters tested, not significant\")\nax.barh(s.index, s.sig, color=\"#b4553a\", label=\"significant\")\nax.set_xlabel(\"IMPC parameters\")\nax.set_title(\"Uroc1 em1(IMPC)Bay homozygous knockout mice: 2 of 330 tests significant\\nno ataxia, no neurodevelopmental or dysmorphology phenotype\")\nax.legend(loc=\"lower right\", fontsize=9)\nplt.tight_layout(); plt.show()\n\n# Orthologs\na=requests.get(\"https://www.alliancegenome.org/api/gene/HGNC:26444/orthologs\",headers=H,timeout=60).json()\nprint(\"\\nOrthologs of human UROC1:\")\nfor o in a.get(\"results\",[]):\n    g=o.get(\"homologGene\") or o.get(\"gene\")\n    if g: print(\"   %-26s %-10s %s  best=%s\"%(g[\"taxon\"][\"name\"], g[\"symbol\"], g[\"id\"], o.get(\"best\")))\n",
  "plot_number": 6
}