mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 06:53:52 +00:00
Merge pull request #1217 from andycheng123/fix/hhllstop
FIX: log hhllStop higher high and lower low detection instead of notify
This commit is contained in:
commit
624489cf65
|
@ -146,10 +146,10 @@ func (s *HigherHighLowerLowStop) updateHighLowNumber(kline types.KLine) {
|
|||
low := kline.GetLow()
|
||||
if s.klines.GetHigh().Compare(high) < 0 {
|
||||
s.highLows = append(s.highLows, types.DirectionUp)
|
||||
Notify("[hhllStop] detected %s new higher high %f", s.Symbol, high.Float64())
|
||||
log.Debugf("[hhllStop] detected %s new higher high %f", s.Symbol, high.Float64())
|
||||
} else if s.klines.GetLow().Compare(low) > 0 {
|
||||
s.highLows = append(s.highLows, types.DirectionDown)
|
||||
Notify("[hhllStop] detected %s new lower low %f", s.Symbol, low.Float64())
|
||||
log.Debugf("[hhllStop] detected %s new lower low %f", s.Symbol, low.Float64())
|
||||
} else {
|
||||
s.highLows = append(s.highLows, types.DirectionNone)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user