This commit is contained in:
2023-05-17 17:21:32 +07:00
parent a114935b2d
commit 6857c249da
4 changed files with 23 additions and 23 deletions

View File

@@ -321,7 +321,7 @@ end
within its radius. radius must be odd number
"""
function normalizePeak!(v::Vector, radius::Integer=2)
peak = findall(isequal.(n.wRec, maximum(n.wRec)))[1]
peak = findall(isequal.(v, maximum(abs.(v))))[1]
upindex = peak - radius
upindex = upindex < 1 ? 1 : upindex
downindex = peak + radius