Documentation
¶
Index ¶
- Constants
- func BasicKLine(securityCode string) pandas.DataFrame
- func CountInflow(list []quotes.TickTransaction, securityCode string, date string) (summary cache.TurnoverDataSummary)
- func GetDataDescript(kind cache.Kind) cache.DataSummary
- func IntegrateQuarterlyReports(barIndex *int, date string) map[string]dfcf.QuarterlyReport
- func KLineToWeekly(kline pandas.DataFrame) pandas.DataFrame
- func MonthlyKLine(securityCode string, cacheKLine ...[]base.KLine) (df pandas.DataFrame)
- func WeeklyKLine(securityCode string, cacheKLine ...[]base.KLine) (df pandas.DataFrame)
- type DataCache
- type DataKLine
- func (k *DataKLine) Check(cacheDate, featureDate string) error
- func (k *DataKLine) Checkout(securityCode, date string)
- func (k *DataKLine) Clone(date, code string) DataSet
- func (k *DataKLine) Filename(date, code string) string
- func (k *DataKLine) Increase(snapshot quotes.Snapshot)
- func (k *DataKLine) Init(ctx context.Context, date, securityCode string) error
- func (k *DataKLine) Key() string
- func (k *DataKLine) Kind() cache.Kind
- func (k *DataKLine) Name() string
- func (k *DataKLine) Owner() string
- func (k *DataKLine) Print(code string, date ...string)
- func (k *DataKLine) Repair(cacheDate, featureDate string)
- func (k *DataKLine) Update(cacheDate, featureDate string)
- func (k *DataKLine) Usage() string
- type DataQuarterlyReport
- func (r *DataQuarterlyReport) Check(cacheDate, featureDate string) error
- func (r *DataQuarterlyReport) Checkout(securityCode, date string)
- func (r *DataQuarterlyReport) Clone(date string, code string) DataSet
- func (r *DataQuarterlyReport) Filename(date, code string) string
- func (r *DataQuarterlyReport) Increase(snapshot quotes.Snapshot)
- func (r *DataQuarterlyReport) Init(ctx context.Context, date, securityCode string) error
- func (r *DataQuarterlyReport) Key() string
- func (r *DataQuarterlyReport) Kind() cache.Kind
- func (r *DataQuarterlyReport) Name() string
- func (r *DataQuarterlyReport) Owner() string
- func (r *DataQuarterlyReport) Print(code string, date ...string)
- func (r *DataQuarterlyReport) Repair(cacheDate, featureDate string)
- func (r *DataQuarterlyReport) Update(cacheDate, featureDate string)
- func (r *DataQuarterlyReport) Usage() string
- type DataSafetyScoredeprecated
- type DataSet
- type DataXdxr
- func (x *DataXdxr) Check(cacheDate, featureDate string) error
- func (x *DataXdxr) Checkout(securityCode, date string)
- func (x *DataXdxr) Clone(date string, code string) DataSet
- func (x *DataXdxr) Filename(date, code string) string
- func (x *DataXdxr) Increase(snapshot quotes.Snapshot)
- func (x *DataXdxr) Init(ctx context.Context, date, securityCode string) error
- func (x *DataXdxr) Key() string
- func (x *DataXdxr) Kind() cache.Kind
- func (x *DataXdxr) Name() string
- func (x *DataXdxr) Owner() string
- func (x *DataXdxr) Print(code string, date ...string)
- func (x *DataXdxr) Repair(cacheDate, featureDate string)
- func (x *DataXdxr) Update(cacheDate, featureDate string)
- func (x *DataXdxr) Usage() string
- type MovingAverage
- type TransactionRecord
- func (r *TransactionRecord) Check(cacheDate, featureDate string) error
- func (r *TransactionRecord) Checkout(securityCode, date string)
- func (r *TransactionRecord) Clone(date string, code string) DataSet
- func (r *TransactionRecord) Filename(date, code string) string
- func (r *TransactionRecord) Increase(snapshot quotes.Snapshot)
- func (r *TransactionRecord) Init(ctx context.Context, date, securityCode string) error
- func (r *TransactionRecord) Key() string
- func (r *TransactionRecord) Kind() cache.Kind
- func (r *TransactionRecord) Name() string
- func (r *TransactionRecord) Owner() string
- func (r *TransactionRecord) Print(code string, date ...string)
- func (r *TransactionRecord) Repair(cacheDate, featureDate string)
- func (r *TransactionRecord) Update(cacheDate, featureDate string)
- func (r *TransactionRecord) Usage() string
Constants ¶
View Source
const ( BaseXdxr = cache.PluginMaskBaseData | (baseKind + 1) // 基础数据-除权除息 BaseKLine = cache.PluginMaskBaseData | (baseKind + 2) // 基础数据-基础K线 BaseTransaction = cache.PluginMaskBaseData | (baseKind + 3) // 基础数据-历史成交 BaseMinutes = cache.PluginMaskBaseData | (baseKind + 4) // 基础数据-分时数据 BaseQuarterlyReports = cache.PluginMaskBaseData | (baseKind + 5) // 基础数据-季报 BaseSafetyScore = cache.PluginMaskBaseData | (baseKind + 6) // 基础数据-安全分 )
Variables ¶
This section is empty.
Functions ¶
func BasicKLine ¶ added in v0.1.5
BasicKLine 基础日K线
func CountInflow ¶ added in v0.2.0
func CountInflow(list []quotes.TickTransaction, securityCode string, date string) (summary cache.TurnoverDataSummary)
CountInflow 统计指定日期的内外盘
func GetDataDescript ¶ added in v0.2.0
func GetDataDescript(kind cache.Kind) cache.DataSummary
func IntegrateQuarterlyReports ¶ added in v0.1.5
func IntegrateQuarterlyReports(barIndex *int, date string) map[string]dfcf.QuarterlyReport
IntegrateQuarterlyReports 更新季报数据
func MonthlyKLine ¶ added in v0.1.5
MonthlyKLine 月K线
Types ¶
type DataCache ¶
type DataCache struct { Date string // 日期 Code string // 证券代码 // contains filtered or unexported fields }
DataCache 基础的数据缓存
type DataKLine ¶
type DataKLine struct {
DataCache
}
type DataQuarterlyReport ¶ added in v0.1.5
type DataQuarterlyReport struct { DataCache // contains filtered or unexported fields }
DataQuarterlyReport 季报
func (*DataQuarterlyReport) Check ¶ added in v0.2.3
func (r *DataQuarterlyReport) Check(cacheDate, featureDate string) error
func (*DataQuarterlyReport) Checkout ¶ added in v0.3.2
func (r *DataQuarterlyReport) Checkout(securityCode, date string)
func (*DataQuarterlyReport) Clone ¶ added in v0.1.5
func (r *DataQuarterlyReport) Clone(date string, code string) DataSet
func (*DataQuarterlyReport) Filename ¶ added in v0.1.5
func (r *DataQuarterlyReport) Filename(date, code string) string
func (*DataQuarterlyReport) Increase ¶ added in v0.1.5
func (r *DataQuarterlyReport) Increase(snapshot quotes.Snapshot)
func (*DataQuarterlyReport) Init ¶ added in v0.1.5
func (r *DataQuarterlyReport) Init(ctx context.Context, date, securityCode string) error
func (*DataQuarterlyReport) Key ¶ added in v0.1.5
func (r *DataQuarterlyReport) Key() string
func (*DataQuarterlyReport) Kind ¶ added in v0.1.5
func (r *DataQuarterlyReport) Kind() cache.Kind
func (*DataQuarterlyReport) Name ¶ added in v0.1.5
func (r *DataQuarterlyReport) Name() string
func (*DataQuarterlyReport) Owner ¶ added in v0.3.2
func (r *DataQuarterlyReport) Owner() string
func (*DataQuarterlyReport) Print ¶ added in v0.2.0
func (r *DataQuarterlyReport) Print(code string, date ...string)
func (*DataQuarterlyReport) Repair ¶ added in v0.1.5
func (r *DataQuarterlyReport) Repair(cacheDate, featureDate string)
func (*DataQuarterlyReport) Update ¶ added in v0.1.5
func (r *DataQuarterlyReport) Update(cacheDate, featureDate string)
func (*DataQuarterlyReport) Usage ¶ added in v0.2.0
func (r *DataQuarterlyReport) Usage() string
type DataSafetyScore
deprecated
added in
v0.1.5
type DataSet ¶
type DataSet interface { cache.Trait cache.DataFile Update(cacheDate, featureDate string) // 更新数据 Repair(cacheDate, featureDate string) // 回补数据 Increase(snapshot quotes.Snapshot) // 增量计算, 用快照增量计算特征 Clone(date string, code string) DataSet // 克隆一个DataSet }
DataSet 数据层, 数据集接口 smart
数据集是基础数据, 应当遵循结构简单, 尽量减小缓存的文件数量, 加载迅速 检索的规则是按日期和代码进行查询
type DataXdxr ¶
type DataXdxr struct {
DataCache
}
type MovingAverage ¶ added in v0.1.5
MovingAverage 移动平均线(MA)
type TransactionRecord ¶ added in v0.2.0
type TransactionRecord struct {
DataCache
}
TransactionRecord 成交记录
最短3秒内的合并统计数据, 与行情数据保持一致 不可以当作tick数据来使用
func (*TransactionRecord) Check ¶ added in v0.2.3
func (r *TransactionRecord) Check(cacheDate, featureDate string) error
func (*TransactionRecord) Checkout ¶ added in v0.3.2
func (r *TransactionRecord) Checkout(securityCode, date string)
func (*TransactionRecord) Clone ¶ added in v0.2.0
func (r *TransactionRecord) Clone(date string, code string) DataSet
func (*TransactionRecord) Filename ¶ added in v0.2.0
func (r *TransactionRecord) Filename(date, code string) string
func (*TransactionRecord) Increase ¶ added in v0.2.0
func (r *TransactionRecord) Increase(snapshot quotes.Snapshot)
func (*TransactionRecord) Init ¶ added in v0.2.0
func (r *TransactionRecord) Init(ctx context.Context, date, securityCode string) error
func (*TransactionRecord) Key ¶ added in v0.2.0
func (r *TransactionRecord) Key() string
func (*TransactionRecord) Kind ¶ added in v0.2.0
func (r *TransactionRecord) Kind() cache.Kind
func (*TransactionRecord) Name ¶ added in v0.2.0
func (r *TransactionRecord) Name() string
func (*TransactionRecord) Owner ¶ added in v0.3.2
func (r *TransactionRecord) Owner() string
func (*TransactionRecord) Print ¶ added in v0.2.0
func (r *TransactionRecord) Print(code string, date ...string)
func (*TransactionRecord) Repair ¶ added in v0.2.0
func (r *TransactionRecord) Repair(cacheDate, featureDate string)
func (*TransactionRecord) Update ¶ added in v0.2.0
func (r *TransactionRecord) Update(cacheDate, featureDate string)
func (*TransactionRecord) Usage ¶ added in v0.2.0
func (r *TransactionRecord) Usage() string
Source Files
¶
Click to show internal directories.
Click to hide internal directories.