From b8c110fddf5eb2dc0cb7acc8fa1f3df41275ee8a Mon Sep 17 00:00:00 2001 From: mbergmann Date: Wed, 23 Oct 2024 09:24:05 +0200 Subject: [PATCH] updated calculate integral --- code/useful_functions.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/useful_functions.py b/code/useful_functions.py index 4038291..1ada50a 100644 --- a/code/useful_functions.py +++ b/code/useful_functions.py @@ -54,7 +54,7 @@ def binary_spikes(spike_times, duration, dt): binary[spike_indices] = 1 # put the indices into binary return binary -def calculate_integral(freq, power, point, delta): +def calculate_integral(freq, power, point, delta = 2.5): """ Calculate the integral around a single specified point. @@ -66,8 +66,8 @@ def calculate_integral(freq, power, point, delta): An array of power spectral density values. point : float The harmonic frequency at which to calculate the integral. - delta : float - Radius of the range for integration around the point. + delta : float, optional + Radius of the range for integration around the point. The default is 2.5. Returns -------