Skip to content

Commit

Permalink
mmtf fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmkrieger committed Nov 8, 2023
1 parent 0a00bfa commit 2adbe8e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions prody/proteins/mmtffile.py
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,9 @@ def set_info(atomgroup, mmtf_data,get_bonds=False,altloc_sel='A'):
if altloc_sel != 'all':
#mask out any unwanted alternative locations
mask = (altlocs == '') | (altlocs == altloc_sel)

if np.all(mask == False):
mask = (altlocs == '') | (altlocs == altlocs[0])

atomgroup.setCoords(coords[:,mask])
atomgroup.setNames(atom_names[mask])
Expand Down

0 comments on commit 2adbe8e

Please sign in to comment.