You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

23 lines
541 B

package indicator
import (
"sig-pub/pkg/types"
"sig-pub/pkg/types/series"
)
// IIndicator 指标基础计算接口
type IIndicator interface {
Calculate() (vector float64)
}
// IKlineSeries k线序列, strategy服务提供
type IKlineSeries interface {
Get(start int16) (kline types.Kline)
Series(start, end int16) (klines series.Klines)
}
// IIndicatorSeries 指标序列, 供策略读取, strategy服务提供
type IIndicatorSeries interface {
Get(start int16) (vector float64)
Series(start, end int16) (matrix series.Floats)
}