Skip to content

Commit

Permalink
Shorter notation
Browse files Browse the repository at this point in the history
  • Loading branch information
MaxvandenBoom committed Jan 8, 2025
1 parent b6a286f commit 7d92cb1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ieegprep/bids/rereferencing.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ def generate_car_per_headbox(cls, channel_names, channel_headboxes):
unique_headboxes = sorted(list(set(channel_headboxes)))
group_counter = 0
for headbox in unique_headboxes:
if is_number(headbox) and not headbox.lower() == 'nan' and not headbox.lower() == 'n/a':

if is_number(headbox) and not str(headbox).lower() in ('nan', 'n/a'):

# find the channel names that belong to this headbox
headbox_channels = [channel_names[ind] for ind, x in enumerate(channel_headboxes) if x == headbox]
Expand Down

0 comments on commit 7d92cb1

Please sign in to comment.