asciireader: make index in label consistent with selection
This commit is contained in:
parent
a3a75f5aee
commit
11715af352
@ -183,7 +183,13 @@ class AsciiReader:
|
||||
single_len = 2
|
||||
stepsize = 2
|
||||
|
||||
cls = {'points': Points, 'fid': FID, 'spectrum': Spectrum, 'bds': BDS, 'dsc': DSC}[mode]
|
||||
cls = {
|
||||
'points': Points,
|
||||
'fid': FID,
|
||||
'spectrum': Spectrum,
|
||||
'bds': BDS,
|
||||
'dsc': DSC,
|
||||
}[mode]
|
||||
|
||||
for j in range(1, num_y+1, stepsize):
|
||||
if col_names is not None:
|
||||
@ -191,7 +197,7 @@ class AsciiReader:
|
||||
kwargs['name'] = col_names[j-1]
|
||||
elif num_y > single_len:
|
||||
# more than one axis, append column number
|
||||
kwargs['name'] = filename + '_' + str(y[j-1])
|
||||
kwargs['name'] = f'{filename}_{y[j-1]+1}'
|
||||
|
||||
if j+num_y < raw_data.shape[2]:
|
||||
kwargs['y_err'] = raw_data[i, :, j+num_y]
|
||||
|
Loading…
Reference in New Issue
Block a user