Skip to content
😱 实时获取所有 A 股现在 + 过去的行情数据,可基于它来做量化交易的行情服务
TypeScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src watch 回调支持异步 Aug 31, 2019
.gitignore 更改下载数据的文件名 Aug 31, 2019
.prettierrc.yaml 创建 Aug 28, 2019
README.md 创建文档 Sep 8, 2019
package.json 发布 Sep 8, 2019
tsconfig.json 更新 Aug 31, 2019
tslint.json 创建 Aug 28, 2019
yarn.lock 创建文档 Sep 8, 2019

README.md

wow-stocks

实时获取所有 A 股现在 + 过去的行情数据,可基于它来做量化交易的行情服务,也可以用来实时选股。

示例

import { update } from 'wow-stocks'
import { ma, cross } from 'wow-stock-calculator'

update({ length: 90 }).then(({ watch }) => {
  watch((stocks) => {
    // 获取当前 5 日均线上穿 10 日均线的所有股票
    console.log(
      stocks.filter((stock) => {
        const ma5 = ma(stock.close, 5)
        const ma10 = ma(stock.close, 10)
        const ma5CrossMa10 = cross(ma5, ma10)
        return ma5CrossMa10[ma5CrossMa10.length - 1]
      }),
    )
  })
})

文档

https://aweiu.com/documents/wow-stocks/

You can’t perform that action at this time.