Skip to content

Commit

Permalink
Check if standard deviation is zero with np.isclose
Browse files Browse the repository at this point in the history
  • Loading branch information
tomasstolker committed Sep 24, 2024
1 parent ed80f58 commit c409f49
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion orbitize/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ def plot_corner(results, param_list=None, **corner_kwargs):
index_num = results.param_idx[label_key]

# only plot non-fixed parameters
if np.std(results.post[:, index_num]) > 0:
if not np.isclose(0.0, np.std(results.post[:, index_num])):
param_indices.append(index_num)
if (
label_key.startswith("aop")
Expand Down

0 comments on commit c409f49

Please sign in to comment.