Skip to content

Commit

Permalink
Merge pull request #90 from MDAnalysis/add-backticks-to-pandas-query()
Browse files Browse the repository at this point in the history
Update speciation.py to use backticks in query()
  • Loading branch information
orionarcher authored Aug 14, 2023
2 parents 8a1f2a9 + 885b536 commit 055cbd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion solvation_analysis/speciation.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ def _solvent_co_occurrence(self):
actual_solvents_list = []
for solvent in self.speciation_data.columns.values:
# calculate number of available coordinating solvent slots
shells_w_solvent = self.speciation_data.query(f'{solvent} > 0')
shells_w_solvent = self.speciation_data.query(f'`{solvent}` > 0')
n_solvents = shells_w_solvent.sum()
# calculate expected number of coordinating solvents
n_coordination_slots = n_solvents.sum() - len(shells_w_solvent)
Expand Down

0 comments on commit 055cbd9

Please sign in to comment.