Skip to content

Commit

Permalink
Corrected typo and extended allowed types for MultiSegmentRecord (#514)
Browse files Browse the repository at this point in the history
Corrected misordered arguments in util.lines_to_file. Added 'list' as
allowed types for seg_name and seg_len, for when writing
MultiSegmentRecords.
  • Loading branch information
briangow authored Nov 8, 2024
2 parents ddf4e20 + 09ea537 commit 11adca8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions wfdb/io/_header.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@
columns=_SPECIFICATION_COLUMNS,
dtype="object",
data=[
[(str), "", None, True, None, None], # seg_name
[int_types, " ", "seg_name", True, None, None], # seg_len
[(str, list), "", None, True, None, None], # seg_name
[(int_types, list), " ", "seg_name", True, None, None], # seg_len
],
)

Expand Down Expand Up @@ -779,7 +779,7 @@ def wr_header_file(self, write_fields, write_dir):
comment_lines = ["# " + comment for comment in self.comments]
header_lines += comment_lines

util.lines_to_file(self.record_name + ".hea", header_lines, write_dir)
util.lines_to_file(self.record_name + ".hea", write_dir, header_lines)

def get_sig_segments(self, sig_name=None):
"""
Expand Down

0 comments on commit 11adca8

Please sign in to comment.