elephant
elephant copied to clipboard
[Bug] Spike-width computation
Describe the bug A colleague and I realized that the waveform_width function doesn't work well for recordings where the action potential is a upward deflection and then a downward one because the code looks for the trough first, then to the next peak.
Therefore, we would suggest having an extension of the function which is flexible to the 2 possible scenarios (trough to peak or peak to trough).
@rsankar9 feel free to expand on this explanation!
Environment
- OS (e.g., Linux): Windows and Mac
- How you installed elephant (
conda
,pip
, source): pip - Python version: 3.9
-
neo
python package version: 0.10.0 -
elephant
python package version: 0.10.0
Hello @E4-IMN ,
thanks a lot for reporting this.
Looking at the provided plot I agree with you. Are you already working on an extension ?
In any case, the development of an extension to this function could benefit from some examples to reproduce the behavior shown above. In case you have some more examples, please do not hesitate to share.