{
  "filename": "evidence_summary.png",
  "iteration": 2,
  "description": "Comprehensive evidence summary figure with sequence identity, domain architecture, active-site motifs, and systematic mis-annotation data",
  "timestamp": "2026-06-24 03:50:38",
  "code": "\nimport matplotlib.pyplot as plt\nimport matplotlib.patches as patches\nimport numpy as np\n\nfig = plt.figure(figsize=(16, 12))\n\n# Create a comprehensive evidence summary figure\ngs = fig.add_gridspec(3, 2, hspace=0.4, wspace=0.3)\n\n# Panel A: Sequence identity comparison\nax1 = fig.add_subplot(gs[0, 0])\ncategories = ['Deaminase\\ndomain', 'Full-length\\n(3-mer est.)']\nadar2_vals = [73.7, 23.9]\nadat1_vals = [56.8, 6.5]\n\nx = np.arange(len(categories))\nwidth = 0.35\nbars1 = ax1.bar(x - width/2, adar2_vals, width, label='vs Human ADAR2', color='#2196F3', edgecolor='black')\nbars2 = ax1.bar(x + width/2, adat1_vals, width, label='vs Human ADAT1', color='#FF9800', edgecolor='black')\n\nax1.set_ylabel('Sequence Identity (%)', fontsize=11)\nax1.set_title('A. Sequence Identity', fontsize=12, fontweight='bold')\nax1.set_xticks(x)\nax1.set_xticklabels(categories)\nax1.legend(fontsize=9)\nax1.set_ylim(0, 100)\n\n# Add value labels\nfor bar in bars1:\n    ax1.text(bar.get_x() + bar.get_width()/2, bar.get_height() + 1, f'{bar.get_height():.1f}%', \n             ha='center', va='bottom', fontsize=9, fontweight='bold')\nfor bar in bars2:\n    ax1.text(bar.get_x() + bar.get_width()/2, bar.get_height() + 1, f'{bar.get_height():.1f}%', \n             ha='center', va='bottom', fontsize=9, fontweight='bold')\n\n# Panel B: Domain count comparison\nax2 = fig.add_subplot(gs[0, 1])\nproteins = ['Squid\\nADAR2', 'Human\\nADAR2', 'Human\\nADAT1']\ndsrbd_counts = [3, 2, 0]\ndeaminase_counts = [1, 1, 1]\n\nx2 = np.arange(len(proteins))\nbars_dsrbd = ax2.bar(x2 - width/2, dsrbd_counts, width, label='dsRBD domains', color='#4CAF50', edgecolor='black')\nbars_deam = ax2.bar(x2 + width/2, deaminase_counts, width, label='Deaminase domain', color='#2196F3', edgecolor='black')\n\nax2.set_ylabel('Domain Count', fontsize=11)\nax2.set_title('B. Domain Architecture', fontsize=12, fontweight='bold')\nax2.set_xticks(x2)\nax2.set_xticklabels(proteins)\nax2.legend(fontsize=9)\nax2.set_ylim(0, 4.5)\n\nfor bar in bars_dsrbd:\n    if bar.get_height() > 0:\n        ax2.text(bar.get_x() + bar.get_width()/2, bar.get_height() + 0.1, f'{int(bar.get_height())}', \n                 ha='center', va='bottom', fontsize=11, fontweight='bold')\n    else:\n        ax2.text(bar.get_x() + bar.get_width()/2, 0.1, '0', \n                 ha='center', va='bottom', fontsize=11, fontweight='bold', color='red')\n\n# Panel C: Active site motif conservation\nax3 = fig.add_subplot(gs[1, :])\nax3.axis('off')\nax3.set_title('C. Active-Site Motif Conservation', fontsize=12, fontweight='bold', pad=20)\n\n# Create a text-based alignment display\nalignment_text = (\n    \"CHAE Catalytic Center (Zn\u00b2\u207a-binding + proton donor):\\n\\n\"\n    \"  Squid ADAR2  (457):  INGEYMNDRGFAVND\u00b7CHAE\u00b7IIARRCFLRFIYDQL\\n\"\n    \"  Human ADAR2  (394):  INGEYMSDRGLALND\u00b7CHAE\u00b7IISRRSLLRFLYTQL\\n\"\n    \"  Human ADAT1       :  \u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7MOTIF ABSENT\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\u00b7\\n\\n\"\n    \"PCG Zinc-Coordinating Cysteine:\\n\\n\"\n    \"  Squid ADAR2  (515):  KLKPNIQFHLYISTA\u00b7PCG\u00b7DARIFSPHGQDVETG\\n\"\n    \"  Human ADAR2  (451):  RLKENVQFHLYISTS\u00b7PCG\u00b7DARIFSPHEPILEGS\\n\"\n    \"  Human ADAT1  (141):  KLRRDLIFVFFSSHT\u00b7PCG\u00b7DASIIPMLEFEDQPC\"\n)\nax3.text(0.05, 0.85, alignment_text, transform=ax3.transAxes, fontsize=9.5,\n         fontfamily='monospace', verticalalignment='top',\n         bbox=dict(boxstyle='round', facecolor='#F5F5F5', edgecolor='#9E9E9E'))\n\n# Add key\nax3.text(0.7, 0.15, \"CHAE = diagnostic for ADAR subfamily\\nPCG = shared across superfamily\",\n         transform=ax3.transAxes, fontsize=9, fontstyle='italic', color='#616161')\n\n# Panel D: Systematic mis-annotation across species\nax4 = fig.add_subplot(gs[2, 0])\nspecies = ['Squid\\nADAR2', 'Human\\nADAR2', 'Mouse\\nAdar2', 'Rat\\nAdar2']\nhas_correct = [1, 1, 1, 1]  # GO:0003726\nhas_incorrect = [1, 1, 1, 1]  # GO:0008251\n\nx4 = np.arange(len(species))\nax4.bar(x4 - width/2, has_correct, width, label='GO:0003726 (dsRNA) \u2705', color='#4CAF50', edgecolor='black')\nax4.bar(x4 + width/2, has_incorrect, width, label='GO:0008251 (tRNA) \u274c', color='#F44336', edgecolor='black')\n\nax4.set_ylabel('Annotation Present', fontsize=11)\nax4.set_title('D. Systematic Mis-annotation', fontsize=12, fontweight='bold')\nax4.set_xticks(x4)\nax4.set_xticklabels(species, fontsize=9)\nax4.legend(fontsize=8, loc='upper right')\nax4.set_ylim(0, 1.5)\nax4.set_yticks([0, 1])\nax4.set_yticklabels(['No', 'Yes'])\n\n# Panel E: Verdict\nax5 = fig.add_subplot(gs[2, 1])\nax5.axis('off')\n\nverdict_text = (\n    \"VERDICT\\n\"\n    \"\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\\n\\n\"\n    \"GO:0008251 is REFUTED\\n\\n\"\n    \"Failure Mode: #3\\n\"\n    \"(Within-superfamily mis-placement)\\n\\n\"\n    \"ADAR2 \u2260 ADAT\\n\\n\"\n    \"Correct term: GO:0003726\\n\"\n    \"(dsRNA adenosine deaminase)\\n\\n\"\n    \"Action: REMOVE GO:0008251\"\n)\n\nax5.text(0.5, 0.5, verdict_text, transform=ax5.transAxes, fontsize=11,\n         ha='center', va='center', fontfamily='monospace', fontweight='bold',\n         bbox=dict(boxstyle='round', facecolor='#FFEBEE', edgecolor='#F44336', linewidth=2))\n\nfig.suptitle('Evidence Summary: Squid ADAR2 (C1JAR3) GO:0008251 Annotation Assessment',\n             fontsize=14, fontweight='bold', y=1.01)\n\nplt.tight_layout()\nplt.savefig('evidence_summary.png', dpi=150, bbox_inches='tight')\nplt.show()\nprint(\"Evidence summary figure saved\")\n"
}