dfcf

package
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 9, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DfcfHistory

type DfcfHistory struct {
	// date        时间
	Date string `json:"date" array:"0"`
	// open       开盘价
	Open float64 `json:"open" array:"1"`
	// high       最高价
	High float64 `json:"high" array:"3"`
	// low        最低价
	Low float64 `json:"low" array:"4"`
	// close      收盘价
	Close float64 `json:"close" array:"2"`
	// volume     成交量, 单位股, 除以100为手
	Volume int64 `json:"volume" array:"5"`
}

func GetHistory

func GetHistory(fullCode string, datalen int) ([]DfcfHistory, error)

GetHistory sina获取历史数据的唯一方法

type EastmoneyApi

type EastmoneyApi struct{}

func (*EastmoneyApi) Name

func (this *EastmoneyApi) Name() string

type KLine

type KLine struct {
	Date   string  `json:"date" array:"0" name:"日期" dataframe:"date,string"`
	Open   float64 `json:"open" array:"1" name:"开盘价" dataframe:"open,float64"`
	Close  float64 `json:"close" array:"2" name:"收盘价" dataframe:"close,float64"`
	High   float64 `json:"high" array:"3" name:"最高价" dataframe:"high,float64"`
	Low    float64 `json:"low" array:"4" name:"最低价" dataframe:"low,float64"`
	Volume int64   `json:"volume" array:"5" name:"成交量" dataframe:"volume,int64"`
	Amount float64 `json:"amount" array:"6" name:"成交金额" dataframe:"amount,float64"`
}

func A

func A(code string) ([]KLine, error)

A 下载A股数据

func (KLine) Init

func (k KLine) Init(_writer *csv.Writer) error

Init 初始化

func (KLine) WriteCSV

func (k KLine) WriteCSV(_writer *csv.Writer) error

WriteCSV 写入

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL