Closed Tomatenbiss closed 3 years ago
Hi @Tomatenbiss Sorry for taking so long to answer the issues you raised.
If you read the article on which the algorithm is based (available here), I think the implementation is correct. The authors define an SCR occurrence as the segment between two consecutive zero-crossings, from negative to positive and positive to negative, and define the SCR amplitude as the maximum value between the two zero-crossings. This also relates to issue #46.
However, I do think that the nomenclature can be misleading, mixing the signal with the SCR from the derivative. We could maybe change the names or descriptions of the outputs.
Do you agree with this interpretation?
Dear @capcarr,
I have read the article and I fully agree with the conclusions you draw from it. But I am also convinced that the code does not represent our interpretation of the algorithm.
An SCR occurs between the Zero crossings for the derivative: Correctly implemented
SCR Amplitude = max. value between Zero Crossings: This is were the issue is. The code takes the maximum value of the derivative(!) in line 232, not the maximum value of the original signal. Taking the highest value of the derivative yields the inflection point of a curve. The second zero crossing yields the position of the curve's peak and should be considered in the code.
I agree that this is related to issue #46 , as this is also caused by checking the amplitude on the derivative instead of checking the original signal.
Please let me know your opinion on this :)
Kind regards Tom
I guess the tool is nice, but such behavior is not documented / it would be nice to know that artefacts are not automatically filtered etc.
Fixed with commit a324641b76ec6e5194c35b247a6d075fa6974940.
I am facing the issue that the eda.eda method returns incorrect positions of the peaks. I already analyzed where the problem is and summarized my findings in the following pdf. I might be wrong so I would be glad to hear your opinion on this.
SCR_Library_PeakPositions.pdf