变化率绝对值算法问题 (#462)
This commit is contained in:
parent
a1130b0e7c
commit
7b220da936
|
@ -388,7 +388,7 @@ func (f CAvgRateAbsFunction) Compute(vs []*dataobj.HistoryData) (leftValue datao
|
|||
}
|
||||
|
||||
value := sum / dataobj.JsonFloat(vsLen)
|
||||
leftValue = dataobj.JsonFloat(math.Abs(float64(value) - float64(f.CompareValue)))
|
||||
leftValue = dataobj.JsonFloat(math.Abs(float64(value)-float64(f.CompareValue)) / f.CompareValue)
|
||||
|
||||
isTriggered = checkIsTriggered(leftValue, f.Operator, f.RightValue)
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue