Skip to content

Commit

Permalink
Change index of LineInteractionTables.lines_data to line_id
Browse files Browse the repository at this point in the history
  • Loading branch information
yeganer committed Oct 6, 2017
1 parent f69f163 commit 1bce042
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tardis/gui/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,7 @@ def __init__(self, line_interaction_analysis, atom_data, lines_data, description
self.layout = QtGui.QHBoxLayout()
self.line_interaction_analysis = line_interaction_analysis
self.atom_data = atom_data
self.lines_data = lines_data
self.lines_data = lines_data.reset_index().set_index('line_data')
line_interaction_species_group = \
line_interaction_analysis.last_line_in.groupby(['atomic_number',
'ion_number'])
Expand Down Expand Up @@ -1009,8 +1009,8 @@ def on_species_clicked(self, index):
exc_deexc_string = 'exc. %d-%d (%.2f A) de-exc. %d-%d (%.2f A)'

for line_id, row in grouped_line_interactions.wavelength.count().iteritems():
current_line_in = self.lines_data.reset_index().set_index('line_id').loc[line_id[0]]
current_line_out = self.lines_data.reset_index().set_index('line_id').loc[line_id[1]]
current_line_in = self.lines_data.loc[line_id[0]]
current_line_out = self.lines_data.loc[line_id[1]]
last_line_in_string.append(exc_deexc_string % (
current_line_in['level_number_lower'],
current_line_in['level_number_upper'],
Expand Down

0 comments on commit 1bce042

Please sign in to comment.