Skip to content

Fixing a bug in SeqIO.PdbIO in parsing pdb-atom sequence - #196

Closed
matsu3shiro wants to merge 1 commit into
biopython:masterfrom
matsu3shiro:master
Closed

matsu3shiro wants to merge 1 commit into
biopython:masterfrom
matsu3shiro:master

Conversation

@matsu3shiro

Copy link
Copy Markdown

Fixing a problem that SeqIO.PdbIO outputs erroneous amino acid sequence
if the ATOM record has more than one missing segments.

SeqIO.PdbIO includes a bug in parsing amino acid sequences
from PDB ATOM records (pdb-atom).
It outputs erroneous amino acid sequence
if the ATOM record has more than one missing segments.

The original code trys to insert 'X's for each gap position,
but it adds the C-terminal sequence from the gap
each time it fills a gap in addition to the 'X's.
In contrast, the insertion of C-terminal sequence is only required
at the final gap position.
Thus, this code outputs an amino acid sequence
in which C-terminal sequence is erroneously repeated
if the coordinate file includes more than one gap positions.

I fixed this bug by moving lines 173-174 out of the FOR loop
starting from line 166.

Fixing a problem that SeqIO.PdbIO outputs erroneous amino acid sequence
if the ATOM record has more than one missing segments.
@etal

etal commented Jul 4, 2013

Copy link
Copy Markdown
Contributor

Thanks for spotting this. Can you suggest a PDB ID we can use for testing? E.g. does this problem occur on 4AZS?

@matsu3shiro

Copy link
Copy Markdown
Author

Dear Eric,

Thank you for your reply.
2XHE will do as a testing case.
I put it in the PDB directory as PDB/2HEX.pdb

I also add some test code in Tests/test_SeqIO_PdbIO.py
in lines 73-82.

Regards,

Matsuyuki Shirota

(2013/07/04 12:21), Eric Talevich wrote:

Thanks for spotting this. Can you suggest a PDB ID we can use for
testing? E.g. does this problem occur on 4AZS?

�$B!=�(B
Reply to this email directly or view it on GitHub
#196 (comment).

@peterjc

peterjc commented Aug 8, 2013

Copy link
Copy Markdown
Member

@etal Are you happy with this pull request (which includes tests)?

@etal

etal commented Aug 9, 2013

Copy link
Copy Markdown
Contributor

Yep, looks good to me. I'll apply it.

@etal etal closed this Aug 9, 2013
@peterjc

peterjc commented Apr 13, 2018

Copy link
Copy Markdown
Member

@matsu3shiro Could you comment on issue #898 if you agree to dual license your Biopython contributions under both the "Biopython License Agreement" and the "BSD 3-Clause License". Many thanks, Peter.

peterjc added a commit that referenced this pull request Apr 13, 2018
This reverts commit 4b3c659.

Have not yet confirmed Matsuyuki Shirota (@matsu3shiro) agrees
to the dual licensing change for his contribution which was
made on pull request #196.
@peterjc

peterjc commented Sep 19, 2018

Copy link
Copy Markdown
Member

Hello again @matsu3shiro - sorry to bother you, but we would still like your agreement to dual license your contribution 5303fbd to Biopython under both the "Biopython License Agreement" and the "BSD 3-Clause License". Many thanks, Peter.

@peterjc peterjc mentioned this pull request Aug 30, 2019
3 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants