# 金融函数 - 股票 / 证券交易时间 ## 函数 ### `stockauctionclosespantrading(auctiontype)` 离指定交易时段截止时间的时长(交易分钟),与系统参数(证券代码,日期))相关 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------ | | `auctiontype` | any | 整型,竞价性质,取值如下: | 返回:any ### `stockauctionopenspannatural(auctiontype)` 离指定交易时段开始时间的时长(自然分钟),与系统参数(证券代码,日期)相关 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------ | | `auctiontype` | any | 整型,竞价性质,取值如下: | 返回:any ### `stockauctionopenspantrading(auctiontype)` 离指定交易时段开始时间的时长(交易分钟),与系统参数(证券代码,日期)相关 注意:交易分钟线是,指定竞价时间点 到 endt的交易分钟线 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------ | | `auctiontype` | any | 整型,竞价类型,取值如下: | 返回:any ### `stockauctiontime(auctiontype, timetype)` 竞价性质的交易时间,与系统参数(证券代码,日期)相关 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------------------- | | `auctiontype` | any | 整型,竞价性质,取值如下: | | `timetype` | any | 整型,时间性质,开始时间=0,截止时间=1 | 返回:string|datetime ### `stockauctiontimelong(auctiontype)` 竞价性质的交易时长(分钟),与系统参数(证券代码,日期)相关 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------ | | `auctiontype` | any | 整型,竞价性质,取值如下: | 返回:any ### `stockcontinuousauctiontime()` 指定日连续竞价时长(分钟),与系统参数(证券代码,日期)相关 返回:any ### `stockisclosecallauction()` 是否有收盘集合竞价,与系统参数(证券代码,日期)相关 返回:bool ### `stockisnightopening()` 是否有夜盘,与系统参数(证券代码,日期)相关 返回:bool ### `stockisopencallauction()` 是否有开盘集合竞价,与系统参数(证券代码,日期)相关 返回:bool ### `stockistradingtime()` 是否为交易时间点,与系统参数(证券代码,日期)相关 返回:bool ### `stocknextauctionopenspannatural(auctiontype)` 离指定交易时段开始时间的时长(未来、自然分钟),与系统参数(证券代码,日期))相关 | 参数 | 类型 | 说明 | | ------------- | ---- | ------------------------ | | `auctiontype` | any | 整型,竞价性质,取值如下: | 返回:float ### `stocknightopeningdate()` 指定品种夜盘开始日,与系统参数(证券代码,日期)相关 返回:any ### `stockopenspantrading()` 已开盘时长(交易分钟),与系统参数(证券代码,日期)相关 返回:float ### `stocktradingnumberchange()` 证券代码对应的交易时间代码,与系统参数(证券代码)相关 各品种代码对照: 大类 取数代码 上交所股票、指数 SH000001 上交所基金 SH000011 上交所债券 SH000012 上交所债券回购 SH204001 上交所期权 OP10000001 深交所股票、指数 SZ399106 深交所基金 SZ399103 深交所债券 SZ399481 深交所债券回购 SZ131810 深交所期权 OP90000001 中证指数 CSI000001 申万指数 SW801003 港股通 HKHSI001 跨市场指数(跨香港交易所) CSICES300 商品期货/股指期货/国债期货 品种代码 商品期权/股指期权 OP+品种代码 返回:string ### `stocktradingtimes()` 证券最近的交易时间序列,与系统参数(证券代码,日期)相关 返回:array ### `stockTradeDateByEndT(type)` 指定日期的交易时段,与日期相关与时间点无关,与系统参数证券代码、日期相关。 | 参数 | 类型 | 说明 | | ------ | ---- | ----------------------------------------- | | `type` | any | Int 是否考虑集合竞价时段 0:不考虑,1:考虑 | 返回:array