Skip to content

Commit

Permalink
Find more reliable dihedral angle target value by testing anti-clockw…
Browse files Browse the repository at this point in the history
…ise and clockwise means (i.e. lower_linear_limit: -340, lower_limit: -320, upper_limit: 20, upper_linear_limit: 40) (8c7a)
  • Loading branch information
yokochi47 committed Mar 29, 2024
1 parent 1487ac7 commit bbc2d8b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions wwpdb/utils/nmr/NmrDpUtility.py
Original file line number Diff line number Diff line change
Expand Up @@ -38818,6 +38818,7 @@ def __calculateStatsOfDihedralRestraint(self, file_list_id, lp_data, conflict_id
upper_limit = None

data_type = row[angle_type_name]

if data_type == 'PPA':
continue

Expand Down
6 changes: 6 additions & 0 deletions wwpdb/utils/nmr/NmrVrptUtility.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,12 @@ def angle_target_values(target_value, target_value_uncertainty,
target_value_vote_clock += 1

if target_value_vote_aclock + target_value_vote_clock == 0 or target_value_vote_aclock * target_value_vote_clock != 0:
if angle_diff(upper_bound, target_value_aclock) > angle_diff(upper_bound, target_value_clock)\
and angle_diff(lower_bound, target_value_aclock) > angle_diff(lower_bound, target_value_clock):
return target_value_aclock, lower_bound, upper_bound
if angle_diff(upper_bound, target_value_clock) > angle_diff(upper_bound, target_value_aclock)\
and angle_diff(lower_bound, target_value_clock) > angle_diff(lower_bound, target_value_aclock):
return target_value_clock, lower_bound, upper_bound
return None, lower_bound, upper_bound

target_value = target_value_aclock if target_value_vote_aclock > target_value_vote_clock else target_value_clock
Expand Down

0 comments on commit bbc2d8b

Please sign in to comment.