indicator: get supertrend signal

This commit is contained in:
Andy Cheng 2022-06-01 11:37:27 +08:00
parent 14e70007d9
commit 39615c8981

View File

@ -107,6 +107,10 @@ func (inc *Supertrend) Update(highPrice, lowPrice, closePrice float64) {
}
}
func (inc *Supertrend) GetSignal() types.Direction {
return inc.tradeSignal
}
var _ types.Series = &Supertrend{}
func (inc *Supertrend) calculateAndUpdate(kLines []types.KLine) {