<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000066">
    Hello Will,<br>
    <br>
    I've come up with a modified version of your ExAC plugin that writes
    AC/AN counts per pop to the output you can check the code here:
    <a class="moz-txt-link-freetext" href="https://github.com/guillermomarco/vep_plugins/blob/master/ExAC.pm">https://github.com/guillermomarco/vep_plugins/blob/master/ExAC.pm</a><br>
    <br>
    However debugging this for the new columns I've found a bug. I'm
    testing the script with the following mutation that has ExAC
    information
    (<a class="moz-txt-link-freetext" href="http://exac.broadinstitute.org/variant/22-46615880-T-C">http://exac.broadinstitute.org/variant/22-46615880-T-C</a>):<br>
    <br>
    22      46615880        rs1800234       T       C       .      
    .       AA=T<br>
     <br>
    All the counts per population and frequencies are identical to those
    in ExAC website, however for the totals I'm getting:<br>
    <ul>
      <li>Allele count: 1163 (OK)</li>
      <li>Allele number: 121412 (this differs from ExAC website that
        shows<b> 120986</b><b style="box-sizing: border-box;
          font-weight: bold; color: rgb(51, 51, 51); font-family:
          'Helvetica Neue', Helvetica, Arial, sans-serif; font-size:
          14px; font-style: normal; font-variant: normal;
          letter-spacing: normal; line-height: 11.4286px; orphans: auto;
          text-align: start; text-indent: 0px; text-transform: none;
          white-space: normal; widows: 1; word-spacing: 0px;
          -webkit-text-stroke-width: 0px; background-color: rgb(255,
          255, 255);"> and its the correct sum total of all the pops)</b></li>
    </ul>
    <p>Maybe there's something else being added up, but I can't find
      where's the problem since all individual allele pop counts are OK.
      Gonna check ExAC VCF for this position to see if I can any clue.<br>
    </p>
    <p>Regards,<br>
      Guillermo.<br>
    </p>
    <div class="moz-cite-prefix">On 02/11/15 09:23, Guillermo Marco
      Puche wrote:<br>
    </div>
    <blockquote cite="mid:56371D84.5040106@sistemasgenomicos.com"
      type="cite">
      <meta http-equiv="content-type" content="text/html;
        charset=windows-1252">
      Hello Will,<br>
      <br>
      I'm interested to print AC and AN count for each population in
      ExAC VEP plugin output. I've modified the following lines to store
      the data:<br>
      <br>
      <meta http-equiv="content-type" content="text/html;
        charset=windows-1252">
      <meta http-equiv="content-type" content="text/html;
        charset=windows-1252">
      <pre style="background-color:#2b2b2b;color:#a9b7c6;font-family:'Source Code Pro';font-size:13.5pt;">  <span style="color:#cc7832;">foreach my </span>$a(@vcf_alleles) {
    <span style="color:#cc7832;">my </span>$ac = <span style="color:#ab51ba;">shift </span>@ac;
    $total_ac += $ac;
    $data->{$a}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh.<span style="color:#6a8759;">'_AC'</span>} = $ac;
    $data->{$a}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh.<span style="color:#6a8759;">'_AN'</span>} = $an;
    $data->{$a}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh} = sprintf(<span style="color:#6a8759;">"%.3g"</span>, $ac / $an);
  }

  <span style="color:#808080;font-style:italic;"># use total to get ref allele freq
</span><span style="color:#808080;font-style:italic;">  </span>$data->{$ref_allele}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh.<span style="color:#6a8759;">'_AC'</span>} = $total_ac;
  $data->{$ref_allele}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh.<span style="color:#6a8759;">'_AN'</span>} = $an;
  $data->{$ref_allele}->{<span style="color:#6a8759;">'ExAC_'</span>.$afh} = sprintf(<span style="color:#6a8759;">"%.3g"</span>, <span style="color:#6897bb;">1 </span>- ($total_ac / $an));
}</pre>
      However I'm getting a bit messy when it comes to header function.
      It loops over ExAC header, but I don't know how to modify
      get_header_info() to output the desired columns.<br>
      <br>
      <br>
      Regards,<br>
      Guillermo.<br>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Dev mailing list    <a class="moz-txt-link-abbreviated" href="mailto:Dev@ensembl.org">Dev@ensembl.org</a>
Posting guidelines and subscribe/unsubscribe info: <a class="moz-txt-link-freetext" href="http://lists.ensembl.org/mailman/listinfo/dev">http://lists.ensembl.org/mailman/listinfo/dev</a>
Ensembl Blog: <a class="moz-txt-link-freetext" href="http://www.ensembl.info/">http://www.ensembl.info/</a>
</pre>
    </blockquote>
  </body>
</html>