Skip to content

Commit

Permalink
Fix new_physio_like function
Browse files Browse the repository at this point in the history
  • Loading branch information
maestroque committed Jul 9, 2024
1 parent 5a42d22 commit e7c66b4
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions physutils/physio.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,10 @@ def new_physio_like(

if suppdata is None:
suppdata = ref_physio._suppdata if copy_suppdata else None

label = ref_physio.label if copy_label else None
physio_type = ref_physio.physio_type if copy_physio_type else None
computed_metrics = list(ref_physio.computed_metrics) if copy_computed_metrics else []

# make new class
out = ref_physio.__class__(
Expand All @@ -228,7 +232,10 @@ def new_physio_like(
history=history,
metadata=metadata,
suppdata=suppdata,
physio_type=physio_type,
label=label,
)
out._computed_metrics = computed_metrics
return out


Expand Down

0 comments on commit e7c66b4

Please sign in to comment.