<div dir="ltr">Thanks... the fix worked for my purposes though i don't use any of those elements so i can't determine whether there were any potential downstream issues with the change.</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 5, 2015 at 7:31 AM, Peter Cock <span dir="ltr"><<a href="mailto:p.j.a.cock@googlemail.com" target="_blank">p.j.a.cock@googlemail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Patrick,<br>
<br>
Assuming Biopython is interpreting the PDB specification correctly,<br>
you should file a bug with Chimera.<br>
<br>
Separately, you could look into replacing this assert statement with<br>
either an error or warning (as used elsewhere in Bio.PDB in order<br>
to tollerate somewhat improper files in strict or permissive mode).<br>
<br>
As a quick hack, do bad things happen if you replace the assert<br>
line with this?:<br>
<br>
element = element.upper() # Hack for tools like Chimera<br>
<br>
Peter<br>
<div><div class="h5"><br>
On Tue, May 5, 2015 at 11:57 AM, Patrick McGrath <<a href="mailto:ptmcgrat@gmail.com">ptmcgrat@gmail.com</a>> wrote:<br>
> Hello,<br>
><br>
> I am trying to use Bio.PDB to read in a PDB file generated from matchmaker<br>
> in chimera. It seems that Chimera changes the HG to Hg and ZN to Zn in the<br>
> last column of the pdb file which causes an error:<br>
><br>
> assert not element or element == element.upper(), element<br>
> AssertionError: Hg<br>
><br>
> Is there any solution to this besides creating a script to manually edit the<br>
> pdb file generated by chimera?<br>
><br>
</div></div>> _______________________________________________<br>
> Biopython mailing list - <a href="mailto:Biopython@mailman.open-bio.org">Biopython@mailman.open-bio.org</a><br>
> <a href="http://mailman.open-bio.org/mailman/listinfo/biopython" target="_blank">http://mailman.open-bio.org/mailman/listinfo/biopython</a><br>
</blockquote></div><br></div>