Skip to content

Commit

Permalink
adding sampling rate parameter to eda_intervalrelated method
Browse files Browse the repository at this point in the history
  • Loading branch information
tilly111 committed Mar 12, 2024
1 parent 3d004b4 commit 67afccc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions neurokit2/eda/eda_analyze.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def eda_analyze(data, sampling_rate=1000, method="auto"):

# Interval-related analysis
elif method in ["interval-related", "interval", "resting-state"]:
features = eda_intervalrelated(data)
features = eda_intervalrelated(data, sampling_rate=sampling_rate)

# Auto
elif method in ["auto"]:
Expand All @@ -106,7 +106,7 @@ def eda_analyze(data, sampling_rate=1000, method="auto"):
for i in data:
duration = len(data[i]) / sampling_rate
if duration >= 10:
features = eda_intervalrelated(data)
features = eda_intervalrelated(data, sampling_rate=sampling_rate)
else:
features = eda_eventrelated(data)

Expand All @@ -117,7 +117,7 @@ def eda_analyze(data, sampling_rate=1000, method="auto"):
else:
duration = len(data) / sampling_rate
if duration >= 10:
features = eda_intervalrelated(data)
features = eda_intervalrelated(data, sampling_rate=sampling_rate)
else:
features = eda_eventrelated(data)

Expand Down

0 comments on commit 67afccc

Please sign in to comment.