Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pdbfixer
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
pdbfixer
Commits
d60306af
Commit
d60306af
authored
Sep 17, 2013
by
Peter Eastman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use MODRES records to identify modified residues
parent
a22bf8e7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletions
+13
-1
pdbfixer.py
+13
-1
No files found.
pdbfixer.py
View file @
d60306af
...
@@ -262,7 +262,19 @@ class PDBFixer(object):
...
@@ -262,7 +262,19 @@ class PDBFixer(object):
self
.
structureChains
=
[
self
.
structureChains
[
i
]
for
i
in
range
(
len
(
self
.
structureChains
))
if
i
not
in
chainIndices
]
self
.
structureChains
=
[
self
.
structureChains
[
i
]
for
i
in
range
(
len
(
self
.
structureChains
))
if
i
not
in
chainIndices
]
def
findNonstandardResidues
(
self
):
def
findNonstandardResidues
(
self
):
self
.
nonstandardResidues
=
[(
r
,
substitutions
[
r
.
name
])
for
r
in
self
.
topology
.
residues
()
if
r
.
name
in
substitutions
]
# First find residues based on our table of standard substitutions.
nonstandard
=
dict
((
r
,
substitutions
[
r
.
name
])
for
r
in
self
.
topology
.
residues
()
if
r
.
name
in
substitutions
)
# Now add ones based on MODRES records.
modres
=
dict
(((
m
.
chain_id
,
m
.
number
,
m
.
residue_name
),
m
.
standard_name
)
for
m
in
self
.
structure
.
modified_residues
)
for
structChain
,
topChain
in
zip
(
self
.
structureChains
,
self
.
topology
.
chains
()):
for
structResidue
,
topResidue
in
zip
(
structChain
.
iter_residues
(),
topChain
.
residues
()):
key
=
(
structChain
.
chain_id
,
structResidue
.
number
,
structResidue
.
name
)
if
key
in
modres
:
nonstandard
[
topResidue
]
=
modres
[
key
]
self
.
nonstandardResidues
=
[(
r
,
nonstandard
[
r
])
for
r
in
sorted
(
nonstandard
,
key
=
lambda
r
:
r
.
index
)]
def
replaceNonstandardResidues
(
self
):
def
replaceNonstandardResidues
(
self
):
if
len
(
self
.
nonstandardResidues
)
>
0
:
if
len
(
self
.
nonstandardResidues
)
>
0
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment