♻️ refactor(tsl): rebuild codegen taxonomy

Move generated builtin and dotnet function docs into the upgraded taxonomy, remove legacy route pages, and regenerate function_index.tsv from markdown headings.
This commit is contained in:
csh
2026-07-07 16:36:08 +08:00
parent 54c1c11e77
commit b6160676b4
763 changed files with 179921 additions and 154583 deletions
@@ -0,0 +1,101 @@
# 数据仓库 / N日
### `deltaOfNDay(exp, n)`
当前值-前N日值。
| 参数 | 类型 | 说明 |
| ----- | ------ | ------------------ |
| `exp` | string | 字符串。统计表达式 |
| `n` | int | 整数。天数 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"SH600585");
SetSysParam(pn_date(),20231010T);
return DeltaOfNDay(@close(),5);
```
### `percentRankOfNDay(exp, n, cache_str)`
当前值在最近N天的百分位排名,Nan值不参与排名。
| 参数 | 类型 | 说明 |
| ----------- | ------ | ------------------ |
| `exp` | string | 字符串。统计表达式 |
| `n` | int | 整数。天数 |
| `cache_str` | string | 字符串。缓存串 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"SH600585");
SetSysParam(pn_date(),20231030T);
return PercentRankOfNDay(@close(),10,"");
```
### `signedPower(exp, n)`
符号次方。特殊当x=0时,N<0,返回NanN=0, 返回1N>0, 返回0。
| 参数 | 类型 | 说明 |
| ----- | ------ | ------------------ |
| `exp` | string | 字符串。函数表达式 |
| `n` | int | 实数。次方 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"SH600585");
SetSysParam(pn_date(),20231030T);
return SignedPower(@close(),3);
```
### `slopeofNday(exp1, exp2, n, cache_str)`
N日线性回归系数。
| 参数 | 类型 | 说明 |
| ----------- | ------ | -------------------- |
| `exp1` | string | 字符串。因变量表达式 |
| `exp2` | string | 字符串。自变量表达式 |
| `n` | int | 整数。交易日天数 |
| `cache_str` | string | 字符串。缓存字段 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"SH600585");
SetSysParam(pn_date(),20231030T);
return SlopeofNday(@close(),@open(),30,"");
```
### `wmaofNday(exp, n, cache_astr)`
N日衰减加权。最新值权重最大,权重归一化,结果同DecayAvgOfNDay。
| 参数 | 类型 | 说明 |
| ------------ | ------ | ------------------ |
| `exp` | string | 字符串。函数表达式 |
| `n` | int | 整数。天数 |
| `cache_astr` | string | 字符串。缓存串 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"SH600585");
SetSysParam(pn_date(),20231030T);
return WmaofNday(@open(),30,"");
```