Compare commits

...

2 Commits

Author SHA1 Message Date
Diana
10b3abc1d8 Merge branch 'main' of https://whale.am28.uni-tuebingen.de/git/mbergmann/gpgrewe2024 2024-10-23 10:52:00 +02:00
Diana
739507722d changed valid_integrals 2024-10-23 10:51:38 +02:00

View File

@ -356,7 +356,7 @@ def spike_times(stim):
return spikes, stim_dur, dt # se changed spike_times to spikes so its not the same as name of function
def valid_integrals(integral, local_mean, threshold, point):
def valid_integrals(integral, local_mean, point, threshold = 0.5):
"""
Check if the integral exceeds the threshold compared to the local mean and
provide feedback on whether the given point is valid or not.
@ -379,7 +379,7 @@ def valid_integrals(integral, local_mean, threshold, point):
message : str
A message stating whether the point is valid or not.
"""
valid = integral > (local_mean * threshold)
valid = integral > (local_mean * (1 + threshold))
if valid:
message = f"The point {point} is valid, as its integral exceeds the threshold."
else: