Skip to content

[Tqsdk-Ci] Update Version 3.8.2 #508

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion PKG-INFO
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: tqsdk
Version: 3.8.1
Version: 3.8.2
Summary: TianQin SDK
Home-page: https://www.shinnytech.com/tqsdk
Author: TianQin
Expand Down
12 changes: 6 additions & 6 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = ["nbsphinx", 'sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx.ext.githubpages', 'autodocsumm', ]
extensions = ["nbsphinx", 'sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx.ext.githubpages', 'autodocsumm', 'sphinxcontrib.googleanalytics']
smartquotes = False

# 设置 graphviz_dot 路径
Expand Down Expand Up @@ -48,9 +48,9 @@
# built documents.
#
# The short X.Y version.
version = u'3.8.1'
version = u'3.8.2'
# The full version, including alpha/beta/rc tags.
release = u'3.8.1'
release = u'3.8.2'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down Expand Up @@ -79,9 +79,9 @@
# html_theme = 'classic'
html_theme = 'sphinx_rtd_theme'

html_theme_options = {
'analytics_id': 'UA-18345151-2',
}
googleanalytics_id = 'G-9SPL7ERCMF'
googleanalytics_enabled = True

# html_sidebars = {
# '**': ['localtoc.html','globaltoc.html','relations.html', 'sourcelink.html', 'searchbox.html'],
# 'using/windows': ['windowssidebar.html', 'searchbox.html'],
Expand Down
74 changes: 39 additions & 35 deletions doc/demo/base.rst
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
.. _demo_base:

基本使用
====================================================
==================================================================

.. contents:: 目录


.. _tutorial-t10:

t10 - 获取实时行情
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t10.py
:language: python
Expand All @@ -18,7 +18,7 @@ t10 - 获取实时行情
.. _tutorial-t20:

t20 - 识别行情更新
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t20.py
:language: python
Expand All @@ -27,7 +27,7 @@ t20 - 识别行情更新
.. _tutorial-t30:

t30 - 使用K线/Tick数据
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t30.py
:language: python
Expand All @@ -36,7 +36,7 @@ t30 - 使用K线/Tick数据
.. _tutorial-t40:

t40 - 下单/撤单
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t40.py
:language: python
Expand All @@ -45,7 +45,7 @@ t40 - 下单/撤单
.. _tutorial-t41:

t41 - 开仓/平仓
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t41.py
:language: python
Expand All @@ -54,7 +54,7 @@ t41 - 开仓/平仓
.. _tutorial-t50:

t50 - 查询交易所合约每日结算价
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t50.py
:language: python
Expand All @@ -63,7 +63,7 @@ t50 - 查询交易所合约每日结算价
.. _tutorial-t51:

t51 - 查询合约成交排名/持仓排名
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t51.py
:language: python
Expand All @@ -72,7 +72,7 @@ t51 - 查询合约成交排名/持仓排名
.. _tutorial-t52:

t52 - 根据合约类型、交易所、品种等条件查询合约
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t52.py
:language: python
Expand All @@ -81,7 +81,7 @@ t52 - 根据合约类型、交易所、品种等条件查询合约
.. _tutorial-t53:

t53 - 查询主连合约对应的标的合约列表
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t53.py
:language: python
Expand All @@ -90,7 +90,7 @@ t53 - 查询主连合约对应的标的合约列表
.. _tutorial-t54:

t54 - 查询合约信息
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t54.py
:language: python
Expand All @@ -99,7 +99,7 @@ t54 - 查询合约信息
.. _tutorial-t55:

t55 - 查询期权合约
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t55.py
:language: python
Expand All @@ -108,7 +108,7 @@ t55 - 查询期权合约
.. _tutorial-t56:

t56 - 根据条件查询期权
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t56.py
:language: python
Expand All @@ -117,7 +117,7 @@ t56 - 根据条件查询期权
.. _tutorial-t57:

t57 - 根据条件查询全部的实值、平值、虚值期权
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t57.py
:language: python
Expand All @@ -126,7 +126,7 @@ t57 - 根据条件查询全部的实值、平值、虚值期权
.. _tutorial-t58:

t58 - 针对ETF期权和股指期权查询全部的实值、平值、虚值期权
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t58.py
:language: python
Expand All @@ -135,7 +135,7 @@ t58 - 针对ETF期权和股指期权查询全部的实值、平值、虚值期
.. _tutorial-t59:

t59 - 查询指定期权的希腊指标
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t59.py
:language: python
Expand All @@ -144,7 +144,7 @@ t59 - 查询指定期权的希腊指标
.. _tutorial-t60:

t60 - 单均线策略
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t60.py
:language: python
Expand All @@ -153,7 +153,7 @@ t60 - 单均线策略
.. _tutorial-t70:

t70 - 简单均线策略(目标持仓模型)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t70.py
:language: python
Expand All @@ -162,23 +162,25 @@ t70 - 简单均线策略(目标持仓模型)
.. _tutorial-t71:

t71 - 简单趋势策略
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t71.py
:language: python


.. _tutorial-t72:

t72 - 隔夜开盘抢单
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t72.py
:language: python


.. _tutorial-t80:

t80 - 价差回归策略
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t80.py
:language: python
Expand All @@ -187,7 +189,7 @@ t80 - 价差回归策略
.. _tutorial-t90:

t90 - 在主图中画指标线
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t90.py
:language: python
Expand All @@ -196,7 +198,7 @@ t90 - 在主图中画指标线
.. _tutorial-t91:

t91 - 在附图中画指标线
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t91.py
:language: python
Expand All @@ -205,7 +207,7 @@ t91 - 在附图中画指标线
.. _tutorial-t92:

t92 - 主图中画信号线及文字标注
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t92.py
:language: python
Expand All @@ -214,7 +216,7 @@ t92 - 主图中画信号线及文字标注
.. _tutorial-t93:

t93 - 在主图中画线和方框
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t93.py
:language: python
Expand All @@ -223,7 +225,7 @@ t93 - 在主图中画线和方框
.. _tutorial-t94:

t94 - 在附图中画K线
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t94.py
:language: python
Expand All @@ -232,7 +234,7 @@ t94 - 在附图中画K线
.. _tutorial-t95:

t95 - 附图中画K线、线段和方框
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t95.py
:language: python
Expand All @@ -241,7 +243,7 @@ t95 - 附图中画K线、线段和方框
.. _tutorial-t96:

t96 - 附图中画MACD
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/t96.py
:language: python
Expand All @@ -250,7 +252,7 @@ t96 - 附图中画MACD
.. _underlying_symbol:

underlying_symbol - 获取主连映射主力合约
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/underlying_symbol.py
:language: python
Expand All @@ -259,15 +261,16 @@ underlying_symbol - 获取主连映射主力合约
.. _tutorial-backtest:

backtest - 回测
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/backtest.py
:language: python


.. _tutorial-downloader:

downloader - 下载数据
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/tutorial/downloader.py
:language: python
Expand All @@ -276,7 +279,7 @@ downloader - 下载数据
.. _tutorial-downloader-orders:

downloader_orders - 下载委托单和成交记录
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/download_orders.py
:language: python
Expand All @@ -285,7 +288,7 @@ downloader_orders - 下载委托单和成交记录
.. _tutorial-ta:

ta - 指标计算
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/ta.py
:language: python
Expand All @@ -294,15 +297,16 @@ ta - 指标计算
.. _tutorial-ta-option:

ta_option - 期权指标计算
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/ta_option.py
:language: python


.. _tutorial-multiaccount:

multiaccount - 多账户
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. literalinclude:: ../../tqsdk/demo/multiaccount.py
:language: python
Expand Down
Loading