diff --git a/bbgo/kline.go b/bbgo/kline.go index 1ed985852..02b4e6d75 100644 --- a/bbgo/kline.go +++ b/bbgo/kline.go @@ -31,7 +31,7 @@ type KLine struct { } func (k KLine) Mid() float64 { - return k.GetHigh() - k.GetLow() / 2 + return (k.GetHigh() + k.GetLow()) / 2 } // green candle with open and close near high price