feat(tsl-api-reference): index class and unit APIs

Migrate reference pages to declaration-line storage and rebuild the
13-column index.

Add qualified member lookup plus regression and end-to-end coverage.
This commit is contained in:
csh
2026-07-29 15:47:46 +08:00
parent 9edc8fc868
commit 13be5ea0aa
239 changed files with 39157 additions and 12846 deletions
File diff suppressed because it is too large Load Diff
@@ -2,6 +2,8 @@
## `warrantCCirculation1(beg_t, end_t)`
声明:function
区间创设规模(万),与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -13,6 +15,8 @@
## `warrantCCirculation2(beg_t, end_t)`
声明:function
区间创设剩余规模(万),与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -2,6 +2,8 @@
## `warrantECirculation(end_t)`
声明:function
指定日权证规模(万),若股票类型为权证,则将表402(权证.权证行权变动)按生效日逆序排列,提取当生效日小于等于截止日时的第一条记录的权证规模/10000;若股票类型不为权证,则返回0,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -12,6 +14,8 @@
## `warrantEPrice(end_t)`
声明:function
指定日行权价,若股票类型为权证,则将表402(权证.权证行权变动)按生效日逆序排列,提取当生效日小于等于截止日时的第一条记录的行权价;若股票类型不为权证,则返回0,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -22,6 +26,8 @@
## `warrantERate(end_t)`
声明:function
指定日行权比例,当股票类型为权证,则将表402(权证.权证行权变动)按生效日逆序排列,提取当生效日小于等于截止日时的第一条记录的行权比例;若股票类型不为权证,则返回0,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -32,6 +38,8 @@
## `warrantExerciseQk(end_t, beg_t)`
声明:function
区间行权变动,将表402(权证.权证行权变动)按生效日逆序排列,当生效日等于开始日且小于等于截止日,且变更原因不为权证创设时,从表中提取股票代码、名称、信息发布日、生效日、权证规模(万)、行权价、行权比例和变更原因,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -43,6 +51,8 @@
## `optionEsiExerciseAmount(end_t, datatype)`
声明:function
指定日行权数量,与系统参数(证券代码)相关。如果指定日有行权交收信息,返回指定日期认购/认沽行权数量;如果指定日没有行权交收信息,返回0。
| 参数 | 类型 | 说明 |
@@ -62,6 +72,8 @@ return optionEsiExerciseAmount(20231227T,0);
## `optionEsiGetdata(stock_id, end_t)`
声明:function
指定日的行权交收信息。
| 参数 | 类型 | 说明 |
@@ -2,6 +2,8 @@
## `warrantBenchClose(endt)`
声明:function
标的收盘价,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -12,12 +14,16 @@
## `warrantBenchId()`
声明:function
标的代码。
返回:string
## `warrantBenchVolatility(endt)`
声明:function
标的证券年波动率(%),标的证券去年到今年截止日(刚好一年)的指定日波动率(%),周期为日线。与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -28,6 +34,8 @@
## `warrantDurationMonth(end_t)`
声明:function
剩余存续期限(月),即当前日与行权截止日之间相距的月数。
| 参数 | 类型 | 说明 |
@@ -38,6 +46,8 @@
## `warrantGearing(end_t)`
声明:function
杠杆倍数,标的证券价格/(权证价格/行权比例),与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -48,6 +58,8 @@
## `warrantNzjz(end_t)`
声明:function
内在价值,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -58,6 +70,8 @@
## `Warrant_OptionTypeByBS(v1, v2)`
声明:function
B-S理论价值,若v1为认购,则返回0,若v2为认沽,则返回1。与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -69,6 +83,8 @@ B-S理论价值,若v1为认购,则返回0,若v2为认沽,则返回1。
## `warrantPriceByBs(end_t)`
声明:function
B-S理论价值,若权证性质为认购,则返回0,若权证性质为认沽,则返回1。与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -79,6 +95,8 @@ B-S理论价值,若权证性质为认购,则返回0,若权证性质为认
## `warrantSjjz(end_t)`
声明:function
时间价值,即权证价格 - 内在价值,与系统证券pn_stock()有关。
| 参数 | 类型 | 说明 |
@@ -89,6 +107,8 @@ B-S理论价值,若权证性质为认购,则返回0,若权证性质为认
## `warrantYhbdl(end_t, rf)`
声明:function
隐含波动率(%),利用权证性质认沽、标的收盘、权证行权价、无风险收益率(%)、权证现价和剩余存续期限来求出隐含波动率(%)。
| 参数 | 类型 | 说明 |
@@ -100,6 +120,8 @@ B-S理论价值,若权证性质为认购,则返回0,若权证性质为认
## `warrantYjl(end_t)`
声明:function
溢价率(%)
| 参数 | 类型 | 说明 |
@@ -110,6 +132,8 @@ B-S理论价值,若权证性质为认购,则返回0,若权证性质为认
## `warrantDurationDay(end_t)`
声明:function
剩余存续期限(天),即当前日与行权截止日之间相距的天数。
| 参数 | 类型 | 说明 |
@@ -120,6 +144,8 @@ B-S理论价值,若权证性质为认购,则返回0,若权证性质为认
## `optionBlackScholesPrice2(contract_type, option_type, s, x, r, std, t, rf)`
声明:function
依据BS定价模型计算期权的价值
| 参数 | 类型 | 说明 |
@@ -145,6 +171,8 @@ return optionBlackScholesPrice2(0,0,9,10,5,20,12,0);
## `optionImpliedVolatilitylu2(contract_type, option_type, s, x, r, close, t, rf, lb, ub)`
声明:function
由期权交易价格依据BS定价模型倒推出的隐含波动率(%),采用二分法优化
| 参数 | 类型 | 说明 |
@@ -172,6 +200,8 @@ return optionImpliedVolatilitylu2(0,0,9,11,2,2,36,0,0,100);
## `optionImpliedVolatility2(contract_type, option_type, s, x, r, close, t, rf)`
声明:function
返回期权的隐含波动率
| 参数 | 类型 | 说明 |
@@ -198,6 +228,8 @@ return optionImpliedVolatility2(0,0,9,11,2,2,36,0);
## `optionBlackScholesRi2(contract_type, option_type, s, x, r, std, t, rf)`
声明:function
返回期权相关的风险指标
| 参数 | 类型 | 说明 |
@@ -223,6 +255,8 @@ return optionBlackScholesRi2(0,0,2.365,2.2,2.75,25,12,0);
## `optionBlackScholesDelta2(contract_type, option_type, s, x, r, std, t, rf)`
声明:function
返回期权相关的风险指标
| 参数 | 类型 | 说明 |