Files
playbook/docs/tsl/codegen/dotnet/fund/portfolio.md
T
csh b6160676b4 ♻️ 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.
2026-07-07 16:36:08 +08:00

8518 lines
205 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 基金 / 投资组合
### `fundarmasset120D(rdate)`
基金指定报告期90天(含)-120天资产(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000009");
return FundARMAsset120D(20191231);
```
### `fundarmasset30D(rdate)`
基金指定报告期30天以内资产(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000009");
return FundARMAsset30D(20191231);
```
### `fundbcarmdebtpercent2(rdate)`
剩余存续期超过397天的浮动利率债券占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcarmdebtvalue(rdate)`
剩余存续期超过397天的浮动利率债券市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcbankbillpercent2(rdate)`
央行票据占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbccbankbillvalue(rdate)`
央行票据市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcconveniblebondpercent1(rdate)`
可转换债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcconveniblebondvalue(rdate)`
可转换债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbccorporatebondpercent2(rdate)`
公司债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbccorporatebondvalue(rdate)`
公司债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcexchangebondpercent1(rdate)`
可交换债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcexchangebondpercent2(rdate)`
可交换债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcexchangebondvalue(rdate)`
可交换债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcfbondpercent1(rdate)`
金融债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcfbondvalue(rdate)`
金融债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcgovbondpercent2(rdate)`
国债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbclocaldebtpercent2(rdate)`
地方政府债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbclocaldebtvalue(rdate)`
地方政府债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcmtnpercent1(rdate)`
中期票据占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcmtnvalue(rdate)`
中期票据市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcncdpercent1(rdate)`
同业存单占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcncdvalue(rdate)`
同业存单市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcotherbondpercent1(rdate)`
其他债券占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcotherbondpercent2(rdate)`
其他债券占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcprivatebondpercent1(rdate)`
中小企业私募债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcprivatebondpercent2(rdate)`
中小企业私募债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcscppercent1(rdate)`
短期融资券占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcscppercent2(rdate)`
短期融资券占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcscpvalue(rdate)`
短期融资券市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| ------- | -------- | ---------- |
| `rdate` | datetime | 指定报告期 |
返回:float
### `fundbcsumnpercentgrow(rdate, rdate2, topn)`
前N名债券类型市值占净值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBCSumNPercentGrow(20191231,20181231,2); //结果:-9.92
```
### `fundbcsumnpercentgrow2(rdate, rdate2, topn)`
前N名债券类型市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBCSumNPercentGrow2(20191231,20181231,2); //结果:-9.50685311820331
```
### `fundbdbondvolumegrowratio(rdate, rdate2, bondid)`
指定债券持有份额变比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `bondid` | string | 字符串,债券代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDBondVolumeGrowRatio(20210331,20191231,"BK180208");
```
### `fundbdnoncode(rdate, topn)`
第N名债券代码,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:string
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDNoNCode(20191231,2); //结果:180409
```
### `fundbdnonpercent(rdate, topn)`
第N名债券市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDNoNPercent(20191231,2); //结果:2.89
```
### `fundbdnonpercent2(rdate, topn)`
第N名债券市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDNoNPercent2(20191231,2); //结果:2.85424365783668
```
### `fundbdnonpercent4(rdate, topn)`
第N名债券市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDNoNPercent4(20191231,2); //结果:14.312663785232
```
### `fundbdsumnpercent(rdate, topn)`
前N名债券市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercent(20191231,2); //结果:6.21
```
### `fundbdsumnpercent2(rdate, topn)`
前N名债券市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercent2(20191231,2); //结果:6.13921182551829
```
### `fundbdsumnpercent3(rdate, topn)`
前N名债券市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercent3(20191231,2); //结果:30.785204522995
```
### `fundbdsumnpercent4(rdate, topn)`
前N名债券市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercent4(20191231,2); //结果:30.785204522995
```
### `fundbdsumnpercentgrow(rdate, rdate2, topn)`
前N名债券市值占净值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercentGrow(20191231,20181231,2); //结果:-7.68
```
### `fundbdsumnpercentgrow2(rdate, rdate2, topn)`
前N名债券市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercentGrow2(20191231,20181231,2); //结果:-7.46155892563982
```
### `fundbdsumnpercentgrow3(rdate, rdate2, topn)`
前N名债券市值占债券市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercentGrow3(20191231,20181231,2); //结果:-12.9956916639413
```
### `fundbdsumnpercentgrow4(rdate, rdate2, topn)`
前N名债券市值占固定收益投资市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNPercentGrow4(20191231,20181231,2); //结果:-12.9956916639413
```
### `fundbdsumnvalue(rdate, topn)`
前N名债券持有市值,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNValue(20191231,2); //结果:285378000
```
### `fundbdsumnvaluegrow(rdate, rdate2, topn)`
前N名债券持有市值变动,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNValueGrow(20191231,20181231,2); //结果:-278679000
```
### `fundbdsumnvaluegrowratio(rdate, rdate2, topn)`
前N名债券持有市值变比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBDSumNValueGrowRatio(20191231,20181231,2); //结果:-49.4061770352996
```
### `fundbsstockbuyamount(rdate, stockid)`
基金指定报告期的指定股票累计买入金额(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundBSStockBuyAmount(20191231,"SZ000002");
```
### `fundbsstockbuypercent(rdate, stockid)`
基金指定报告期的指定股票累计买入金额占期初净值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSStockBuyPercent(20191231,"SH601336");
```
### `fundbsstockbuypercent2(rdate, stockid)`
基金指定报告期的指定股票累计买入金额占期初总值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSStockBuyPercent2(20191231,"SH601336");
```
### `fundbsstockbuypercent3(rdate, stockid)`
基金指定报告期的指定股票累计买入金额占期初股票市值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSStockBuyPercent3(20191231,"SH601336");
```
### `fundbsstockbuyrank(rdate, stockid)`
基金指定报告期的指定股票累计买入排名
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
计算基金OF006872在2019年报关于SZ300760累计买入排名
SetSysParam(pn_stock(),"OF006872");
return FundBSStockBuyRank(20191231,"SZ300760");
```
### `fundbsstocksellpercent(rdate, stockid)`
基金指定报告期的指定股票累计卖出金额占期初净值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSStockSellPercent(20191231,"SH601336");
```
### `fundbssumnbuyamount(rdate, topn)`
基金指定报告期的前N名股票累计买入金额(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNBuyAmount(20191231,3);
```
### `fundbssumnbuypercent2(rdate, topn)`
基金指定报告期的前N名股票累计买入金额占期初总值比(%) ;
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNBuyPercent2(20191231,3);
```
### `fundbssumnbuypercent3(rdate, topn)`
基金指定报告期的前N名股票累计买入金额占期初股票市值比(%) ;
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNBuyPercent3(20191231,3);
```
### `fundbssumnsellamount(rdate, topn)`
基金指定报告期的前N名股票累计卖出金额(万);
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNSellAmount(20191231,3);
```
### `fundbssumnsellpercent(rdate, topn)`
基金指定报告期的前N名股票累计卖出金额占期初净值比(%);
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNSellPercent(20191231,3);
```
### `fundbssumnsellpercent3(rdate, topn)`
基金指定报告期的前N名股票累计卖出金额占期初股票市值比(%);
| 参数 | 类型 | 说明 |
| ------- | ---- | ----------------------------------------------------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundBSSumNSellPercent3(20191231,3);
```
### `fundcbbondpercent(rdate, stockid)`
基金指定报告期指定可转债市值占净值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBBondPercent(20191231,"SZ128016");
```
### `fundcbbondpercent2(rdate, stockid)`
基金指定报告期指定可转债市值占总值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBBondPercent2(20191231,"SZ128016");
```
### `fundcbbondvalue(rdate, stockid)`
基金指定报告期指定可转债持有市值(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBBondValue(20191231,"SZ128016");
```
### `fundcbnoncode(rdate, topn)`
基金指定报告期第N名可转债证券代码
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:string
#### 示例
```tsl
计算基金OF000001在2019年报第1名可转债证券代码
SetSysParam(pn_stock(),"OF000001");
return FundCBNoNCode(20191231,1);
```
### `fundcbnonpercent(rdate, topn)`
基金指定报告期第N名可转债市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBNoNPercent(20191231,1);
```
### `fundcbnonpercent2(rdate, topn)`
基金指定报告期第N名可转债市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBNoNPercent2(20191231,1);
```
### `fundcbnonvalue(rdate, topn)`
基金指定报告期第N名可转债持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBNoNValue(20191231,1);
```
### `fundcbsumnpercent(rdate, topn)`
基金指定报告期前N名可转债市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBSumNPercent(20191231,3);
```
### `fundcbsumnpercent2(rdate, topn)`
基金指定报告期前N名可转债市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBSumNPercent2(20191231,3);
```
### `fundcbsumnpercent3(rdate, topn)`
基金指定报告期前N名可转债市值占债券市值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBSumNPercent3(20191231,3);
```
### `fundcbsumnvalue(rdate, topn)`
基金指定报告期前N名可转债持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundCBSumNValue(20191231,3);
```
### `fundfdfundpercent(rdate, stockid)`
基金指定报告期指定基金市值占净值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundFDFundPercent(20191231,"OF003349");
```
### `fundfdfundpercentgrow(rdate, rdate2, stockid)`
基金指定报告期指定基金市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDFundPercentGrow(20191231,20181231,"OF004496");
```
### `fundfdfundvalue(rdate, stockid)`
基金指定报告期指定基金持有市值(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundFDFundValue(20191231,"OF003349");
```
### `fundfdfundvaluegrow(rdate, rdate2, stockid)`
基金指定报告期指定基金持有市值变动(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000008");
return FundFDFundValueGrow(20191231,20181231,"OF159922");
```
### `fundfdfundvolume(rdate, stockid)`
基金指定报告期指定基金持有份额
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
计算基金OF006872在2019年报关于OF003349的持有份额
SetSysParam(pn_stock(),"OF006872");
return FundFDFundVolume(20191231,"OF003349");
```
### `fundfdfundvolumegrow(rdate, rdate2, stockid)`
基金指定报告期指定基金持有份额变动
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,基金代码 |
返回:float
#### 示例
```tsl
计算基金OF005809在2019年报关于OF004496的持有份额变动
SetSysParam(pn_stock(),"OF005809");
return FundFDFundVolumeGrow(20191231,20181231,"OF004496");
```
### `fundfdmanagerpercent(rdate)`
基金指定报告期持有关联基金市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundFDManagerPercent(20191231);
```
### `fundfdmanagerpercent2(rdate)`
基金指定报告期持有关联基金市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundFDManagerPercent2(20191231);
```
### `fundfdmanagerpercentgrow(rdate, rdate2)`
基金指定报告期持有关联基金市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000008");
return FundFDManagerPercentGrow(20191231,20181231);
```
### `fundfdmanagerpercentgrow2(rdate, rdate2)`
基金指定报告期持有关联基金市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000008");
return FundFDManagerPercentGrow2(20191231,20181231);
```
### `fundfdmanagerpercentgrow3(rdate, rdate2)`
基金指定报告期持有关联基金市值占基金市值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDManagerPercentGrow3(20191231,20181231);
```
### `fundfdmanagervalue(rdate)`
基金指定报告期持有关联基金市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF006872");
return FundFDManagerValue(20191231);
```
### `fundfdmanagervaluegrow(rdate, rdate2)`
基金指定报告期持有关联基金市值变动(万)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000008");
return FundFDManagerValueGrow(20191231,20181231);
```
### `fundfdmanagervaluegrowratio(rdate, rdate2)`
基金指定报告期持有关联基金市值变比(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000008");
return FundFDManagerValueGrowRatio(20191231,20181231);
```
### `fundfdnoncode(rdate, topn)`
基金指定报告期第N名基金代码
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:string
#### 示例
```tsl
计算基金OF005809在2019年报第3名基金代码
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNCode(20191231,3);
```
### `fundfdnonpercent(rdate, topn)`
基金指定报告期第N名基金市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNPercent(20191231,3);
```
### `fundfdnonpercent2(rdate, topn)`
基金指定报告期第N名基金市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:string
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNPercent2(20191231,3);
```
### `fundfdnonpercent3(rdate, topn)`
基金指定报告期第N名基金市值占基金市值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:string
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNPercent3(20191231,3);
```
### `fundfdnonvalue(rdate, topn)`
基金指定报告期第N名基金持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNValue(20191231,3);
```
### `fundfdnonvolume(rdate, topn)`
基金指定报告期第N名基金持有份额
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
计算基金OF005809在2019年报第3名基金持有份额
SetSysParam(pn_stock(),"OF005809");
return FundFDNoNVolume(20191231,3);
```
### `fundfdsumnpercent(rdate, topn)`
基金指定报告期前N名基金市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercent(20191231,3);
```
### `fundfdsumnpercent2(rdate, topn)`
基金指定报告期前N名基金市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercent2(20191231,3);
```
### `fundfdsumnpercent3(rdate, topn)`
基金指定报告期前N名基金市值占基金市值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercent3(20191231,3);
```
### `fundfdsumnpercentgrow(rdate, rdate2, topn)`
基金指定报告期前N名基金市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercentGrow(20191231,20181231,3);
```
### `fundfdsumnpercentgrow2(rdate, rdate2, topn)`
基金指定报告期前N名基金市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercentGrow2(20191231,20181231,3);
```
### `fundfdsumnpercentgrow3(rdate, rdate2, topn)`
基金指定报告期前N名基金市值占基金市值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNPercentGrow3(20191231,20181231,3);
```
### `fundfdsumnvalue(rdate, topn)`
基金指定报告期前N名基金持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNValue(20191231,3);
```
### `fundfdsumnvaluegrow(rdate, rdate2, topn)`
基金指定报告期前N名基金持有市值变动(万)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNValueGrow(20191231,20181231,3);
```
### `fundfdsumnvaluegrowratio(rdate, rdate2, topn)`
基金指定报告期前N名基金持有市值变比(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF005809");
return FundFDSumNValueGrowRatio(20191231,20181231,3);
```
### `fundHkStocksPercent(stock_id, rdate)`
获取基金指定报告期港股占净值比例.
| 参数 | 类型 | 说明 |
| ---------- | ------ | ----------------- |
| `stock_id` | string | 证券,证券代码 |
| `rdate` | int | 报告期,指定报告期 |
返回:float
### `fundhsorganvalue(rdate)`
基金指定报告期内机构持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundHSOrganValue(20191231);
```
### `fundhsothergrow2(rdate, rdate2)`
基金指定报告期内其他持有份额变动
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
计算基金OF159919在2014年报的其他持有份额变动
SetSysParam(pn_stock(),"OF159919");
return FundHSOtherGrow2(20141231,20131231);
```
### `fundIcCentralizationGrow(r_date, r_date2, industry_name)`
返回指定行业投资市值变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------------- | ---- | -------- |
| `r_date` | int | 报告期 |
| `r_date2` | int | 报告期 |
| `industry_name` | int | 行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate1:=20110630;
RDate2:=20100630;
Return FundICCentralizationGrow(RDate1,RDate2,10);
```
### `fundicindustrypercent3(rdate, name)`
指定行业市值占股票市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `name` | string | 字符串,行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICIndustryPercent3(20191231,"金融业"); //结果:7.45005479951638
```
### `fundicindustrypercentgrow2(rdate, rdate2, name)`
指定行业市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `name` | string | 字符串,行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICIndustryPercentGrow2(20191231,20181231,"金融业");
```
### `fundicindustrypercentgrow3(rdate, rdate2, name)`
指定行业市值占股票市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `name` | string | 字符串,行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICIndustryPercentGrow3(20191231,20181231,"金融业");
```
### `fundicindustryrank(rdate, name)`
指定行业市值排名,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `name` | string | 字符串,行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICIndustryRank(20191231,"金融业"); //结果:4
```
### `fundIcInfo(report_date, to_no)`
返回基金指定报告期的前N名行业明细,行业名称、市值、占净值比例(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| ------------- | ---- | ---------- |
| `report_date` | int | 报告期 |
| `to_no` | int | 用户自定义 |
返回:array
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate:=20100331;
Return FundICInfo(RDate,3);
```
### `fundIcInfo2(r_date, to_no)`
返回基金指定报告期的行业投资情况(不含制造业),行业名称、市值、占净值比例(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | ---------- |
| `r_date` | int | 报告期 |
| `to_no` | int | 用户自定义 |
返回:array
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate:=20100331;
Return FundICInfo2(RDate,3);
```
### `fundIcMarketValue2(report_date, to_no)`
返回基金指定报告期的前N名行业市值和,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| ------------- | ---- | ---------- |
| `report_date` | int | 报告期 |
| `to_no` | int | 用户自定义 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate:=20100331;
Return FundICMarketValue2(RDate,10);
```
### `fundIcMarketValue2Grow(r_date, r_date2, to_no)`
返回基金的前N名行业市值变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------- | ---- | ---------- |
| `r_date` | int | 报告期 |
| `r_date2` | int | 报告期 |
| `to_no` | int | 用户自定义 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate1:=20110630;
RDate2:=20100630;
Return FundICMarketValue2Grow(RDate1,RDate2,10);
```
### `fundIcMarketValueGrowRatio(r_date, r_date2, industry_name)`
返回基金指定行业投资市值变比(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------------- | ------ | -------- |
| `r_date` | int | 报告期 |
| `r_date2` | int | 报告期 |
| `industry_name` | string | 行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate1:=20110630;
RDate2:=20100630;
Return FundICMarketValueGrowRatio(RDate1,RDate2,'金融、保险业') ;
```
### `fundicnonpercent(rdate, topn)`
第N名行业市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICNoNPercent(20191231,1); //结果:44.09
```
### `fundicnonpercent2(rdate, topn)`
第N名行业市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICNoNPercent2(20191231,1); //结果:43.6123705431576
```
### `fundicnonpercent3(rdate, topn)`
第N名行业市值占股票市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICNoNPercent3(20191231,1); //结果:58.2870653063485
```
### `fundicnonpercentgrow2(rdate, rdate2, topn)`
第N名行业市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICNoNPercentGrow2(20191231,20181231,1);
```
### `fundicnonvalue(rdate, topn)`
第N名行业市值,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICNoNValue(20191231,1); //结果:2027297873.83
```
### `fundIcPercentage(report_date, industry_name)`
返回指定行业占净值比例(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------------- | ------ | -------- |
| `report_date` | int | 报告期 |
| `industry_name` | string | 行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate:=20100331;
Return FundSCCentralization(RDate,'金融、保险业');
```
### `fundIcPercentage2Grow(r_date, r_date2, to_no)`
返回基金前N名行业占净值比例变动(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------- | ---- | ---------- |
| `r_date` | int | 报告期 |
| `r_date2` | int | 报告期 |
| `to_no` | int | 用户自定义 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate1:=20110630;
RDate2:=20100630;
Return FundICPercentage2Grow(RDate1,RDate2,10);
```
### `fundIcPercentageGrow(r_date, r_date2, industry_name)`
返回基金的指定行业占净值比例变动(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --------------- | ------ | -------- |
| `r_date` | int | 报告期 |
| `r_date2` | int | 报告期 |
| `industry_name` | string | 行业名称 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate1:=20110630;
RDate2:=20100630;
return FundICPercentageGrow(RDate1,RDate2,'金融、保险业');
```
### `fundicsumnpercent2(rdate, topn)`
前N名行业市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICSumNPercent2(20191231,1); //结果:12.9
```
### `fundicsumnpercentgrow2(rdate, rdate2, topn)`
前N名行业市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF000001");
return FundICSumNPercentGrow2(20191231,20181231,1);
```
### `fundirfieldvalue(rdate, field)`
资产配置-指定字段数据
| 参数 | 类型 | 说明 |
| ------- | -------- | --------------- |
| `rdate` | datetime | 报告期, |
| `field` | string | 字段名称,string |
返回:float
### `fundirothervalue(rdate)`
资产配置-其他资产市值
| 参数 | 类型 | 说明 |
| ------- | -------- | ------ |
| `rdate` | datetime | 报告期 |
返回:float
### `fundirtotalassetvalue(rdate)`
资产配置-资产总值
| 参数 | 类型 | 说明 |
| ------- | -------- | ------ |
| `rdate` | datetime | 报告期 |
返回:float
### `fundpmnonpercent(rdate, topn)`
基金指定报告期第N名贵金属市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMNoNPercent(20181231,1);
```
### `fundpmnonpercent2(rdate, topn)`
基金指定报告期第N名贵金属市值占总值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMNoNPercent2(20191231,1);
```
### `fundpmnonpercent3(rdate, topn)`
基金指定报告期第N名贵金属市值占贵金属市值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMNoNPercent3(20191231,1);
```
### `fundpmnonvalue(rdate, topn)`
基金指定报告期第N名贵金属持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMNoNValue(20191231,1);
```
### `fundpmnonvolume(rdate, topn)`
基金指定报告期第N名贵金属持有份额
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
计算基金OF002610在2019年报第1名贵金属持有份额
SetSysParam(pn_stock(),"OF002610");
return FundPMNoNVolume(20191231,1);
```
### `fundpmsecuritypercent(rdate, stockid)`
基金指定报告期指定贵金属市值占净值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityPercent(20181231,"Au9999");
```
### `fundpmsecuritypercent2(rdate, stockid)`
基金指定报告期指定贵金属市值占总值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityPercent2(20191231,"Au9999");
```
### `fundpmsecuritypercent3(rdate, stockid)`
基金指定报告期指定贵金属市值占贵金属投资市值比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityPercent3(20191231,"Au9999");
```
### `fundpmsecuritypercentgrow(rdate, rdate2, stockid)`
基金指定报告期指定贵金属市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityPercentGrow(20191231,20181231,"Au9999");
```
### `fundpmsecuritypercentgrow2(rdate, rdate2, stockid)`
基金指定报告期指定贵金属市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityPercentGrow2(20191231,20181231,"Au9999");
```
### `fundpmsecurityvalue(rdate, stockid)`
基金指定报告期指定贵金属持有市值(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityValue(20191231,"Au9999");
```
### `fundpmsecurityvaluegrow(rdate, rdate2, stockid)`
基金指定报告期指定贵金属持有市值变动(万)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityValueGrow(20191231,20181231,"Au9999");
```
### `fundpmsecurityvaluegrowratio(rdate, rdate2, stockid)`
基金指定报告期指定贵金属持有市值变比(%)
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityValueGrowRatio(20191231,20181231,"Au9999");
```
### `fundpmsecurityvolume(rdate, stockid)`
基金指定报告期指定贵金属持有份额
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
计算基金OF002610在2019年报Au9999持有份额
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityVolume(20191231,"Au9999");
```
### `fundpmsecurityvolumegrow(rdate, rdate2, stockid)`
基金指定报告期指定贵金属持有份额变动
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
计算基金OF002610在2018年报Au9999持有份额变动
SetSysParam(pn_stock(),"OF002610");
return FundPMSecurityVolumeGrow(20181231,20171231,"Au9999");
```
### `fundpmsumnpercent(rdate, topn)`
基金指定报告期前N名贵金属市值占净值比(%)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNPercent(20181231,1);
```
### `fundpmsumnpercentgrow(rdate, rdate2, topn)`
基金指定报告期前N名贵金属市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNPercentGrow(20191231,20181231,1);
```
### `fundpmsumnpercentgrow2(rdate, rdate2, topn)`
基金指定报告期前N名贵金属市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNPercentGrow2(20191231,20181231,1);
```
### `fundpmsumnpercentgrow3(rdate, rdate2, topn)`
基金指定报告期前N名贵金属市值占贵金属市值比变动(%)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNPercentGrow3(20191231,20181231,1);
```
### `fundpmsumnvalue(rdate, topn)`
基金指定报告期前N名贵金属持有市值(万)
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNValue(20191231,1);
```
### `fundpmsumnvaluegrow(rdate, rdate2, topn)`
基金指定报告期前N名贵金属持有市值变动(万)
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF002610");
return FundPMSumNValueGrow(20191231,20181231,1);
```
### `fundScIncludeStockId(report_date, to_no, stock_id)`
基金的前N名股票是否包含指定的股票。与系统股票pn_stock()、当前时间pn_date()相关。
| 参数 | 类型 | 说明 |
| ------------- | -------- | --------------------- |
| `report_date` | datetime | 报告期类型,报告期; |
| `to_no` | int | 整型,前N名,取值如下 |
| `stock_id` | string | 证券类型,股票代码 |
返回:bool
#### 示例
```tsl
setsysparam(pn_stock(),"OF162714");
Return FundSCIncludeStockId(20180630,10,"SH600718");
```
### `fundScMarketValue(report_date, to_no)`
返回基金前N名持股的股票市值和,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| ------------- | ---- | --------------------- |
| `report_date` | int | 报告期 |
| `to_no` | int | 整型,前N名,取值如下 |
返回:int
#### 示例
```tsl
SetSysParam(pn_stock(),'OF040001');
RDate:=20100331;
return FundSCMarketValue(RDate,10);
```
### `fundscnonindexvalue(rdate, topn)`
第N名股票指数投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNIndexValue(20191231,2); //结果:1683554509
```
### `fundscnonindexvolume(rdate, topn)`
第N名股票指数投资股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNIndexVolume(20191231,2); //结果:1423123
```
### `fundscnonpercent(rdate, topn)`
第N名股票市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNPercent(20191231,2); //结果:4.18
```
### `fundscnonpercent2(rdate, topn)`
第N名股票市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNPercent2(20191231,2); //结果:4.16797774282387
```
### `fundscnonpercent3(rdate, topn)`
第N名股票市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNPercent3(20191231,2); //结果:4.21127420209799
```
### `fundscnonpercent4(rdate, topn)`
第N名股票市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNPercent4(20191231,2); //结果:4.21127420209799
```
### `fundscnonvalue(rdate, topn)`
第N名股票持有市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNValue(20191231,2); //结果:1683554509
```
### `fundscnonvolume(rdate, topn)`
第N名股票持有股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,第N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCNoNVolume(20191231,2); //结果:1423123
```
### `fundscstockactivepercent(rdate, stockid)`
指定股票积极投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercent(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivepercent2(rdate, stockid)`
指定股票积极投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercent2(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivepercent3(rdate, stockid)`
指定股票积极投资市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercent3(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivepercent4(rdate, stockid)`
指定股票积极投资市值占积极投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercent4(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivepercent5(rdate, stockid)`
指定股票积极投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercent5(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivepercentgrow(rdate, rdate2, stockid)`
指定股票积极投资市值占净值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercentGrow(20191231,20181231,'SZ000002'); //结果:0
```
### `fundscstockactivepercentgrow2(rdate, rdate2, stockid)`
指定股票积极投资市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercentGrow2(20191231,20181231,"SZ000002"); //结果:0
```
### `fundscstockactivepercentgrow3(rdate, rdate2, stockid)`
指定股票积极投资市值占股票市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercentGrow3(20191231,20181231,"SZ000002"); //结果:0
```
### `fundscstockactivepercentgrow4(rdate, rdate2, stockid)`
指定股票积极投资市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActivePercentGrow4(20191231,20181231,"SZ000002");
```
### `fundscstockactivevalue(rdate, stockid)`
指定股票积极投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActiveValue(20191231,"SZ000002"); //结果:0
```
### `fundscstockactivevaluegrow(rdate, rdate2, stockid)`
指定股票积极投资市值变动,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActiveValueGrow(20191231,20181231,"SZ000002"); //结果:0
```
### `fundscstockactivevaluegrowratio(rdate, rdate2, stockid)`
指定股票积极投资市值变比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActiveValueGrowRatio(20191231,20181231,"SZ000002"); //结果:0
```
### `fundscstockactivevolume(rdate, stockid)`
指定股票积极投资股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockActiveVolume(20191231,"SZ000002"); //结果:0
```
### `fundscstockindexpercent(rdate, stockid)`
指定股票指数投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockIndexPercent(20191231,"SZ000002"); //结果:1.35
```
### `fundscstockindexpercent2(rdate, stockid)`
指定股票指数投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockIndexPercent2(20191231,"SZ000002"); //结果:1.35187633739411
```
### `fundScStockIndexPercent3(rdate, stock_id)`
指定股票指数投资市值占股票市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| ---------- | ------ | ---------------- |
| `rdate` | int | 整数。指定报告期 |
| `stock_id` | string | 字符串。股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockIndexPercent3(20191231,"SZ000002");
```
### `fundscstockindexpercent4(rdate, stockid)`
指定股票指数投资市值占指数投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockIndexPercent4(20191231,"SZ000002"); //结果:1.36591946871515
```
### `fundscstockpercent4(rdate, stockid)`
指定股票市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockPercent4(20191231,"SZ000002"); //结果:1.36591946871515
```
### `fundscstockpercentgrow(rdate, rdate2, stockid)`
指定股票市值占净值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockPercentGrow(20191231,20181231,"SZ000002"); //结果:0.12
```
### `fundscstockpercentgrow2(rdate, rdate2, stockid)`
指定股票市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockPercentGrow2(20191231,20181231,"SZ000002");
```
### `fundscstockpercentgrow3(rdate, rdate2, stockid)`
指定股票市值占股票市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockPercentGrow3(20191231,20181231,"SZ000002");
```
### `fundscstockpercentgrow4(rdate, rdate2, stockid)`
指定股票市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockPercentGrow4(20191231,20181231,"SZ000002");
```
### `fundscstockvaluegrow(rdate, rdate2, stockid)`
指定股票持有市值变动,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockValueGrow(20191231,20181231,"SZ000002"); //结果:134879568.8
```
### `fundscstockvaluegrowratio(rdate, rdate2, stockid)`
指定股票持有市值变比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --------- | ------ | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `stockid` | string | 字符串,股票代码 |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCStockValueGrowRatio(20191231,20181231,"SZ000002");
```
### `fundscsumnactivepercent2(rdate, topn)`
前N名股票积极投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActivePercent2(20191231,2); //结果:0
```
### `fundscsumnactivepercent4(rdate, topn)`
前N名股票积极投资市值占积极投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActivePercent4(20191231,2); //结果:0
```
### `fundscsumnactivevalue(rdate, topn)`
前N名股票积极投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValue(20191231,2); //结果:0
```
### `fundscsumnactivevaluegrow(rdate, rdate2, topn)`
前N名股票积极投资市值变动,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValueGrow(20191231,20181231,2); //结果:0
```
### `fundscsumnactivevaluegrowratio(rdate, rdate2, topn)`
前N名股票积极投资市值变比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValueGrowRatio(20191231,20181231,2); //结果:0
```
### `fundscsumnactivevaluegrowratio2(rdate, rdate2, topn)`
前N名股票积极投资市值占净值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValueGrowRatio2(20191231,20181231,2); //结果:0
```
### `fundscsumnactivevaluegrowratio3(rdate, rdate2, topn)`
前N名股票积极投资市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValueGrowRatio3(20191231,20181231,2); //结果:0
```
### `fundscsumnactivevaluegrowratio5(rdate, rdate2, topn)`
前N名股票积极投资市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNActiveValueGrowRatio5(20191231,20181231,2); //结果:0
```
### `fundScSumNIndexValueGrow(rdate, rdate2, top_n)`
前N名股票指数投资市值变动,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | ---------------- |
| `rdate` | int | 整数。指定报告期 |
| `rdate2` | int | 整数。同比报告期 |
| `top_n` | int | 整数。前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNIndexValueGrow(20191231,20181231,2);
```
### `fundscsumnpercent2(rdate, topn)`
前N名股票市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNPercent2(20191231,2); //结果:10.8037555610196
```
### `fundscsumnpercent4(rdate, topn)`
前N名股票市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNPercent4(20191231,2); //结果:10.9159836945456
```
### `fundscsumnvaluegrowratio3(rdate, rdate2, topn)`
前N名股票市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNValueGrowRatio3(20191231,20181231,2); //结果:1.1756998821252
```
### `fundscsumnvaluegrowratio5(rdate, rdate2, topn)`
前N名股票市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
| `topn` | int | 整型,前N |
返回:float
#### 示例
```tsl
SetSysParam(pn_stock(),"OF510300");
return FundSCSumNValueGrowRatio5(20191231,20181231,2); //结果:1.25504141189035
```
### `fundssnetassetvolume(rdate)`
指定报告期基金总份额,与当前证券相关
| 参数 | 类型 | 说明 |
| ------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
返回:float
#### 示例
```tsl
计算基金OF006872在2019年报的基金总份额
SetSysParam(pn_stock(),"OF006872");
return FundSSNetAssetVolume(20191231);
```
### `fundsspurchasevolume(rdate, rdate2)`
指定报告期基金净申购份额,与当前证券相关
| 参数 | 类型 | 说明 |
| -------- | ---- | --------------- |
| `rdate` | int | 整型,指定报告期 |
| `rdate2` | int | 整型,同比报告期 |
返回:float
#### 示例
```tsl
计算基金OF000001在2019年报的基金净申购份额
SetSysParam(pn_stock(),"OF000001");
return FundSSPurchaseVolume(20191231,20181231);
```
### `fundscompanylist(fundarr)`
基金公司List,与系统参数无关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundarr` | array of string | array of string,基金列表 |
返回:array
### `fundscale()`
基金规模
返回:boolean
#### 示例
```tsl
//获取OF510050在20240823的基金规模
setSysParam(pn_stock(),"OF510050");
setSysParam(pn_date(),20240823T);
return fundscale();
```
### `fundScCentralizationGrow(r_date, r_date2, to_no)`
返回基金的持股集中度变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 同比报告期 |
| `to_no` | Integer | 整数,详情 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报与2010年中报的前十大持股的集中度的变动
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundScCentralizationGrow(r_date1,r_date2,10);
//结果:8.37
```
### `fundScHoldAmount(report_date, to_no)`
返回基金指定报告期的前N名持股股数和,与系统证券pn_stock()相关。(废弃)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `report_date` | Integer | 报告期 |
| `to_no` | Integer | 整数,详情如下所示。 |
返回:Int
#### 示例
```tsl
//获得华安创新2010一季报公布的前10名持股股数和
setSysParam(pn_stock(),'OF040001');
r_date:=20100331;
return fundScHoldAmount(r_date,10);
//结果:91966000
```
### `fundScCentralization(report_date, to_no)`
返回基金的持股集中度,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `report_date` | Integer | 报告期 |
| `to_no` | Integer | 整型,前N名,取值如下 |
返回:Int
#### 示例
```tsl
//返回华安创新2010年一季报的前十名的持股集中度
setSysParam(pn_stock(),'OF040001');
r_date:=20100331;
return fundScCentralization(r_date,10);
//结果:37.45
```
### `fundScInfo(rdate, top_n)`
返回基金指定报告期前N名股票明细,与系统函数pn_stock()有关
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | integer | 报告期 |
| `top_n` | integer | 第N |
返回:Array,TableArray
#### 示例
```tsl
//获得华安创新2010年一季报前3名股票明细
setSysParam(pn_stock(),'OF040001');
r_date:=20100331;
return fundScInfo(r_date,3);
结果:
```
### `fundScMarketValueGrow(r_date, r_date2, to_no)`
返回基金前N名持股的股票市值和的变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
| `to_no` | Integer | 整型,前N名,取值如下 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报与2010年中报前10大持股的股票市值和的变动
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundScMarketValueGrow(r_date1,r_date2,10);
//结果:709404118.56
```
### `fundScMarketValueGrowRatio(r_date, r_date2, to_no)`
返回基金前N名持股的股票市值和的变动比(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
| `to_no` | Integer | 整型,具体如下所示 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报与2010年中报的前10大持股股票市值和的变动比(%)
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
ReturnFundSCMarketValueGrowRatio(r_date1,r_date2,10);
//结果:51.61
```
### `fundScPercentGrow(r_date, r_date2, to_no)`
返回基金的前N名持股占净值比例和的变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
| `to_no` | Integer | 整型,取值如下 |
返回:Real
#### 示例
```tsl
//返回华夏创新在2010年一季报和中报的前十名持股的占净值比例和的变动
setSysParam(pn_stock(),'OF040001');
r_date1:=20100331;
r_date2:=20100630;
return fundScPercentGrow(r_date2,r_date1,10);
//结果:-3.99
```
### `fundScPercentage(report_date, to_no)`
返回基金指定报告期的前N名持股占净值比例之和,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `report_date` | Integer | 报告期 |
| `to_no` | Integer | 整型,取值如下 |
返回:Real
#### 示例
```tsl
//返回基金在2010年一季报的前10名持股占净值比例和
setSysParam(pn_stock(),'OF040001');
r_date:=20100331;
return fundScPercentage(r_date,10);
//结果:24.44
```
### `fundscnonactivepercent(rdate, topn)`
第N名股票积极投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值占净值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonactivepercent(20191231,2); //结果:0
```
### `fundscnonactivepercent2(rdate, topn)`
第N名股票积极投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值占总值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonactivepercent2(20191231,2); //结果:0
```
### `fundscnonactivepercent3(rdate, topn)`
第N名股票积极投资市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值占股票市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonactivepercent3(20191231,2); //结果:0
```
### `fundscnonactivepercent4(rdate, topn)`
第N名股票积极投资市值占积极投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值占积极投资部分比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonactivepercent4(20191231,2); //结果:0
```
### `fundscnonactivepercent5(rdate, topn)`
第N名股票积极投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值占权益投资市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonactivepercent5(20191231,2); //结果:0
```
### `fundscnonactivevalue(rdate, topn)`
第N名股票积极投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资市值
setSysParam(pn_stock(),"OF510300");
return fundscnonactivevalue(20191231,2); //结果:0
```
### `fundscnonactivevolume(rdate, topn)`
第N名股票积极投资股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票积极投资股数
setSysParam(pn_stock(),"OF510300");
return fundscnonactivevolume(20191231,2); //结果:0
```
### `fundscnoncode(rdate, topn)`
第N名股票代码,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:STRING
#### 示例
```tsl
// "OF510300"在20191231第2名股票代码
setSysParam(pn_stock(),"OF510300");
return fundscnoncode(20191231,2); //结果:SH600519
```
### `fundscnonindexpercent(rdate, topn)`
第N名股票指数投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票指数投资市值占净值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonindexpercent(20191231,2); //结果:4.18
```
### `fundscnonindexpercent2(rdate, topn)`
第N名股票指数投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票指数投资市值占总值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonindexpercent2(20191231,2); //结果:4.16797774282387
```
### `fundscnonindexpercent3(rdate, topn)`
第N名股票指数投资市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票指数投资市值占股票市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonindexpercent3(20191231,2); //结果:4.21127420209799
```
### `fundscnonindexpercent4(rdate, topn)`
第N名股票指数投资市值占指数投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票指数投资市值占指数投资部分比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonindexpercent4(20191231,2); //结果:4.21127420209799
```
### `fundscnonindexpercent5(rdate, topn)`
第N名股票指数投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231第2名股票指数投资市值占权益投资市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscnonindexpercent5(20191231,2); //结果:4.21127420209799
```
### `fundscstockindexpercent5(rdate, stockid)`
指定股票指数投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A指数投资市值占权益投资市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexpercent5(20191231,"SZ000002"); //结果:1.36591946871515
```
### `fundscstockindexpercentgrow(rdate, rdate2, stockid)`
指定股票指数投资市值占净值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间第2名股票指数投资市值占净值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexpercentgrow(20191231,20181231,2); //结果:0.12
```
### `fundscstockindexpercentgrow2(rdate, rdate2, stockid)`
指定股票指数投资市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间万科A指数投资市值占总值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexpercentgrow2(20191231,20181231,"SZ000002");
//结果:0.119102751396919
```
### `fundscstockindexpercentgrow3(rdate, rdate2, stockid)`
指定股票指数投资市值占股票市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间万科A指数投资市值占股票市值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexpercentgrow3(20191231,20181231,2);
//结果:0.128935091068871
```
### `fundscstockindexpercentgrow4(rdate, rdate2, stockid)`
指定股票指数投资市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间万科A指数投资市值占权益投资市值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexpercentgrow4(20191231,20181231,'SZ000002');
//结果:0.128935091068871
```
### `fundscstockindexvalue(rdate, stockid)`
指定股票指数投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A指数投资市值
setSysParam(pn_stock(),"OF510300");
return fundscstockindexvalue(20191231,'SZ000002'); //结果:546057979.16
```
### `fundscstockindexvaluegrow(rdate, rdate2, stockid)`
指定股票指数投资市值变动,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间万科A指数投资市值变动
setSysParam(pn_stock(),"OF510300");
return fundscstockindexvaluegrow(20191231,20181231,'SZ000002');
//结果:134879568.8
```
### `fundscstockindexvaluegrowratio(rdate, rdate2, stockid)`
指定股票指数投资市值变比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间指数投资市值变比(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockindexvaluegrowratio(20191231,20181231,"SZ000002");
//结果:32.8031738538773
```
### `fundscstockindexvolume(rdate, stockid)`
指定股票指数投资股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A指数投资股数
setSysParam(pn_stock(),"OF510300");
return fundscstockindexvolume(20191231,'SZ000002'); //结果:16968862
```
### `fundscstockpercent(rdate, stockid)`
指定股票市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A市值占净值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockpercent(20191231,"SZ000002"); //结果:1.35
```
### `fundscstockpercent2(rdate, stockid)`
指定股票市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A市值占总值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockpercent2(20191231,"SZ000002"); //结果:1.35187633739411
```
### `fundscstockpercent3(rdate, stockid)`
指定股票市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A指定股票市值占股票市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscstockpercent3(20191231,"SZ000002"); //结果:1.36591946871515
```
### `fundscstockvalue(rdate, stockid)`
指定股票持有市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A积持有市值
setSysParam(pn_stock(),"OF510300");
return fundscstockvalue(20191231,"SZ000002"); //结果:546057979.16
```
### `fundscstockvolume(rdate, stockid)`
指定股票持有股数,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231万科A股票持有股数
setSysParam(pn_stock(),"OF510300");
return fundscstockvolume(20191231,"SZ000002"); //结果:16968862
```
### `fundscsumnactivepercent(rdate, topn)`
前N名股票积极投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票积极投资市值占净值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnactivepercent(20191231,2); //结果:0
```
### `fundscsumnactivepercent3(rdate, topn)`
前N名股票积极投资市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票积极投资市值占股票市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnactivepercent3(20191231,2); //结果:0
```
### `fundscsumnactivepercent5(rdate, topn)`
前N名股票积极投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票积极投资市值占权益投资市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnactivepercent5(20191231,2); //结果:0
```
### `fundscsumnactivevaluegrowratio4(rdate, rdate2, topn)`
前N名股票积极投资市值占股票市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间前2名股票积极投资市值占股票市值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnactivevaluegrowratio4(20191231,20181231,2); //结果:0
```
### `fundscsumnindexpercent(rdate, topn)`
前N名股票指数投资市值占净值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值占净值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexpercent(20191231,2); //结果:10.83
```
### `fundscsumnindexpercent2(rdate, topn)`
前N名股票指数投资市值占总值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值占总值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexpercent2(20191231,2); //结果:10.8037555610196
```
### `fundscsumnindexpercent3(rdate, topn)`
前N名股票指数投资市值占股票市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值占股票市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexpercent3(20191231,2); //结果:10.9159836945456
```
### `fundscsumnindexpercent4(rdate, topn)`
前N名股票指数投资市值占指数投资部分比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值占指数投资部分比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexpercent4(20191231,2); //结果:10.9159836945456
```
### `fundscsumnindexpercent5(rdate, topn)`
前N名股票指数投资市值占权益投资市值比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值占权益投资市值比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexpercent5(20191231,2); //结果:10.9159836945456
```
### `fundscsumnindexvalue(rdate, topn)`
前N名股票指数投资市值,与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231前2名股票指数投资市值
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvalue(20191231,2); //结果:4363917590.54
```
### `fundscsumnindexvaluegrowratio(rdate, rdate2, topn)`
前N名股票指数投资市值变比(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231前2名指数投资市值变比(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvaluegrowratio(20191231,20181231,2);
//结果:35.8910845392378
```
### `fundscsumnindexvaluegrowratio2(rdate, rdate2, topn)`
前N名股票指数投资市值占净值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间前2名股票指数投资市值占净值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvaluegrowratio2(20191231,20181231,2); //结果:1.18
```
### `fundscsumnindexvaluegrowratio3(rdate, rdate2, topn)`
前N名股票指数投资市值占总值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231前2名股票指数投资市值占总值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvaluegrowratio3(20191231,20181231,2); //结果:1.1756998821252
```
### `fundscsumnindexvaluegrowratio4(rdate, rdate2, topn)`
前N名股票指数投资市值占股票市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间前2名股票指数投资市值占股票市值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvaluegrowratio4(20191231,20181231,2);
//结果:1.25504141189035
```
### `fundscsumnindexvaluegrowratio5(rdate, rdate2, topn)`
前N名股票指数投资市值占权益投资市值比变动(%),与当前证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF510300"在20191231与20181231期间前2名股票指数投资市值占权益投资市值比变动(%)
setSysParam(pn_stock(),"OF510300");
return fundscsumnindexvaluegrowratio5(20191231,20181231,2);
//结果:1.25504141189035
```
### `fundScValue(rdate, stock_id)`
指定股票相关数据,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整数。指定报告期 |
| `stock_id` | String | 字符串。股票代码 |
返回:Array
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundScValue(20231231,'SZ002230');
结果:
```
### `fundScSumN(rdate, top_n, field)`
前N名股票相关数据,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。前N |
| `field` | String | 字符串。列名 |
返回:Real
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundScSumN(20231231,10,'市值');
//结果:709906215.11
```
### `fundScValue2(rdate, stock_id, field)`
指定股票指定列相关数据,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | integer | 整数。指定报告期 |
| `stock_id` | String | 字符串。股票代码 |
| `field` | String | 字符串。列名 |
返回:real
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundScValue2(20231231,'SZ002230','市值');
//结果:45953304
```
### `fundbcenterprisebondpercent1(rdate)`
企业债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcgovbondvalue(rdate)`
国债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcncdpercent2(rdate)`
同业存单占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcmtnpercent2(rdate)`
中期票据占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcfbondpercent2(rdate)`
金融债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbccorporatebondpercent1(rdate)`
公司债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbclocaldebtpercent1(rdate)`
地方政府债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcenterprisebondpercent2(rdate)`
企业债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcotherbondvalue(rdate)`
其他债券市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcbondpercent2(rdate, name)`
指定债券类型市值占总值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
| `name` | string | 债券类型 |
返回:real
### `fundbcarmdebtpercent1(rdate)`
剩余存续期超过397天的浮动利率债券占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcenterprisebondvalue(rdate)`
企业债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcprivatebondvalue(rdate)`
中小企业私募债市值,与系统参数(基金)相关。单位:元。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcbondpercentgrow2(rdate, rdate2, name)`
指定债券类型市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值占总值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercentgrow2(20191231,20181231,"国债"); //结果:-1.23
```
### `fundbcgovbondpercent1(rdate)`
国债占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcbankbillpercent1(rdate)`
央行票据占净值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcconveniblebondpercent2(rdate)`
可转换债占债券市值比(%),与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
返回:real
### `fundbcbondpercent3(rdate, name)`
指定债券类型市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券类型市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercent3(20191231,"国债"); //结果:1.11
```
### `fundbcbondpercent4(rdate, name)`
指定债券类型市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券类型市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercent4(20191231,"国债"); //结果:1.10841752508523
```
### `fundbcbondpercentgrow(rdate, rdate2, name)`
指定债券类型市值占净值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值占净值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercentgrow(20191231,20181231,"国债"); //结果:-1.26
```
### `fundbcbondpercentgrow3(rdate, rdate2, name)`
指定债券类型市值占债券市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值占债券市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercentgrow3(20191231,20181231,"国债");
//结果:-3.55152582173095
```
### `fundbcbondpercentgrow4(rdate, rdate2, name)`
指定债券类型市值占固定收益投资市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值占固定收益投资市值比变动
setSysParam(pn_stock(),"OF000001");
return fundbcbondpercentgrow4(20191231,20181231,"国债");
//结果:-3.55152582173095
```
### `fundbcbondvaluegrow(rdate, rdate2, name)`
指定债券类型市值变动,单位:元。与系统参数(基金)相关。单位:元。与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值变动
setSysParam(pn_stock(),"OF000001");
return fundbcbondvaluegrow(20191231,20181231,"国债");
//结果:-49762000
```
### `fundbcbondvaluegrowratio(rdate, rdate2, name)`
指定债券类型市值变比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `name` | String | 字符串,债券类型 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券类型市值变比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcbondvaluegrowratio(20191231,20181231,"国债");
//结果:-82.8855539084231
```
### `fundbcnonname(rdate, topn)`
第N名债券类型名称,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:STRING
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型名称
setSysParam(pn_stock(),"OF000001");
return fundbcnonname(20191231,2); //结果:中期票据
```
### `fundbcnonpercent(rdate, topn)`
第N名债券类型市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercent(20191231,2); //结果:2.2
```
### `fundbcnonpercent2(rdate, topn)`
第N名债券类型市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型市值占总值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercent2(20191231,2);
//结果:2.17362923158186
```
### `fundbcnonpercent3(rdate, topn)`
第N名债券类型市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercent3(20191231,2);
//结果:10.8997086846338
```
### `fundbcnonpercent4(rdate, topn)`
第N名债券类型市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercent4(20191231,2);
//结果:10.8997086846338
```
### `fundbcnonpercentgrow(rdate, rdate2, topn)`
第N名债券类型市值占净值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间第2名债券类型市值占净值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercentgrow(20191231,20181231,2); //结果:-0.29
```
### `fundbcnonpercentgrow2(rdate, rdate2, topn)`
第N名债券类型市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间第2名债券类型市值占总值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercentgrow2(20191231,20181231,2);
//结果:-0.26799288508768
```
### `fundbcnonpercentgrow3(rdate, rdate2, topn)`
第N名债券类型市值占债券市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间第2名债券类型市值占债券市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercentgrow3(20191231,20181231,2);
//结果:3.04012437331564
```
### `fundbcnonpercentgrow4(rdate, rdate2, topn)`
第N名债券类型市值占固定收益投资市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间第2名债券类型市值占固定收益投资市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcnonpercentgrow4(20191231,20181231,2);
//结果:3.04012437331564
```
### `fundbcnonvalue(rdate, topn)`
第N名债券类型持有市值,与系统参数(基金)相关。单位:元。与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券类型持有市值
setSysParam(pn_stock(),"OF000001");
return fundbcnonvalue(20191231,2); //结果:101040000
```
### `fundbcnonvaluegrow(rdate, rdate2, topn)`
第N名债券类型持有市值变动,单位:元。与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间第2名债券类型持有市值变动
setSysParam(pn_stock(),"OF000001");
return fundbcnonvaluegrow(20191231,20181231,2); //结果:-220000
```
### `fundbcsumnpercent(rdate, topn)`
前N名债券类型市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231前2名债券类型市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercent(20191231,2); //结果:19.91
```
### `fundbcsumnpercent2(rdate, topn)`
前N名债券类型市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231前2名债券类型市值占总值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercent2(20191231,2);
//结果:19.6952584471872
```
### `fundbcsumnpercent3(rdate, topn)`
前N名债券类型市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231前2名债券类型市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercent3(20191231,1); //结果:87.86
```
### `fundbcsumnpercent4(rdate, topn)`
前N名债券类型市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231前2名债券类型市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercent4(20191231,2); //结果:98.7622803483759
```
### `fundbcsumnpercentgrow3(rdate, rdate2, topn)`
前N名债券类型市值占债券市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间前2名债券类型市值占债券市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercentgrow3(20191231,20181231,2); //结果:4.76065071464147
```
### `fundbcsumnpercentgrow4(rdate, rdate2, topn)`
前N名债券类型市值占固定收益投资市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间前2名债券类型市值占固定收益投资市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnpercentgrow4(20191231,20181231,2); //结果:4.76065071464147
```
### `fundbcsumnvalue(rdate, topn)`
前N名债券类型持有市值,与系统参数(基金)相关。单位:元。与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231前2名债券类型持有市值
setSysParam(pn_stock(),"OF000001");
return fundbcsumnvalue(20191231,2); //结果:915523625
```
### `fundbcsumnvaluegrow(rdate, rdate2, topn)`
前N名债券类型持有市值变动,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间前2名债券类型持有市值变动
setSysParam(pn_stock(),"OF000001");
return fundbcsumnvaluegrow(20191231,20181231,2);
//结果:-295558875
```
### `fundbcsumnvaluegrowratio(rdate, rdate2, topn)`
前N名债券类型市值变比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间前2名债券类型市值变比(%)
setSysParam(pn_stock(),"OF000001");
return fundbcsumnvaluegrowratio(20191231,20181231,2);
//结果:-24.4045203361456
```
### `fundbcbondpercent(rdate, name)`
指定债券类型市值占净值比(%),与系统参数(证券)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
| `name` | string | 债券类型 |
返回:real
### `fundbcbondvalue(rdate, name)`
指定债券类型持有市值,单位:元。与系统参数(证券)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
| `name` | string | 债券类型 |
返回:real
### `fundbcvalue(rdate, btype)`
指定报告期债券配置相关数据,与系统参数(证券)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 指定报告期 |
| `btype` | string | 返回类型 |
返回:array
### `fundBcBondSumN(rdate, top_n, field)`
前N名债券类型持有数据,与系统参数(证券)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。前N |
| `field` | String | 字符串。列名 |
返回:Real
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundBcBondSumN(20221231,3,'市值');
//结果:658056005.48
```
### `fundBcBondNoN(rdate, top_n, field)`
第N名债券类型持有数据,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。第N |
| `field` | String | 字符串。列名 |
返回:Real
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundBcBondNoN(20221231,3,'市值');
//结果:110787178.08
```
### `fundIrStockValue(r_date)`
基金的资产配置-股票市值,从表基金.资产配置(322)中取股票市值。与系统股票pn_stock()、当前时间pn_date(),相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | RDate | 报告期类型,报告期; |
返回:Real
#### 示例
```tsl
//OF1627142018年中报的股票市值。
setSysParam(pn_stock(),"OF162714");
return fundIrStockValue(20180630);
//结果:75934603.15
```
### `fundIrBondPercent(r_date)`
返回基金的债券占净值比例(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//取得华安创新2011年年报公布的债券占净值比例(%)
setSysParam(pn_stock(),'OF040001');
r_date:=20111231;
return fundIrBondPercent(r_date);
//结果:26.48
```
### `fundIrBondPercentGrow(r_date, r_date2)`
返回基金的债券现金占净值比例变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//比较华安创新 2011年中报与2010年中报的债券现金占净值比例变动情况
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrBondPercentGrow(r_date1,r_date2);
//结果:-10.55
```
### `fundIrBondValue(r_date)`
返回基金指定报告期的债券市值,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Int | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报的债券市值
setSysParam(pn_stock(),'OF040001');
r_date:=20110630;
return fundIrBondValue(r_date);
//结果:1656960130.7
```
### `fundIrBondValueGrow(r_date, r_date2)`
返回基金的债券现金变动(增长),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//比较华安创新 2011年中报与2010年中报中债券现金变动情况
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrBondValueGrow(r_date1,r_date2);
//结果:-581095932
```
### `fundIrBondValueGrowRatio(r_date, r_date2)`
返回基金的债券现金变比(增长率)(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//比较华安创新2011年中报与2010年中报的债券现金变比(增长率)(%)
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrBondValueGrowRatio(r_date1,r_date2);
//结果:-25.96
```
### `fundIrNetAssetValue(r_date)`
返回基金指定报告期的资产净值,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新 2011年中报公布的资产净值
setSysParam(pn_stock(),'OF040001');
r_date:=20110630;
return fundIrNetAssetValue(r_date);
//结果:7285618761.52
```
### `fundIrNetAssetValueGrow(r_date, r_date2)`
返回基金的资产净值变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报和2010年中报的资产净值的变动
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrNetAssetValueGrow(r_date1,r_date2);
//结果:563746056.32
```
### `fundIrNetAssetValueGrowRatio(r_date, r_date2)`
返回基金的资产净值变动比值,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报和2010年中报的资产净值变动比值
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrNetAssetValueGrowRatio(r_date1,r_date2);
//结果:8.39
```
### `fundIrStockPercent(r_date)`
返回基金的股票占净值比例(%),与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报的公布的股票占净值比例(%)
setSysParam(pn_stock(),'OF040001');
r_date:=20110630;
return fundIrStockPercent(r_date);
//结果:66.35
```
### `fundIrStockValueGrow(r_date, r_date2)`
返回基金的股票市值变动,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报2010年中报的股票市值变动
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrStockValueGrow(r_date1,r_date2);
//结果:876888161.01
```
### `fundIrStockValueGrowRatio(r_date, r_date2)`
返回基金的股票市值变动比值,与系统证券pn_stock()相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 报告期 |
| `r_date2` | Integer | 报告期 |
返回:Real
#### 示例
```tsl
//返回华安创新2011年中报与2010年中报股票市值变动的比值
setSysParam(pn_stock(),'OF040001');
r_date1:=20110630;
r_date2:=20100630;
return fundIrStockValueGrowRatio(r_date1,r_date2);
//结果:22.16
```
### `fundircashvalue(rdate)`
资产配置-银行存款和清算备付金市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundirabsvalue(rdate)`
资产配置-资产支持证券市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundirresalevalue(rdate)`
资产配置-买入返售证券市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundirderivativesvalue(rdate)`
资产配置-金融衍生品市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundirrepurchasevalue(rdate)`
资产配置-卖出回购证券市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundirfundvalue(rdate)`
资产配置-基金市值
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | rdate | 报告期 |
返回:real
### `fundhsorgangrow(rdate, rdate2)`
基金指定报告期内机构持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的机构持有市值变动(万)
setSysParam(pn_stock(),"OF000001");
return fundhsorgangrow(20191231,20181231);
//返回:860.475365116
```
### `fundhsorgangrow2(rdate, rdate2)`
基金指定报告期内机构持有份额变动
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报的机构持有份额变动
setSysParam(pn_stock(),"OF000009");
return fundhsorgangrow2(20191231,20181231);
//返回:-517584542.92
```
### `fundhsorganpercent(rdate)`
基金指定报告期内机构持有市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的机构持有市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundhsorganpercent(20191231);
//返回:0.452437302449383
```
### `fundhsorganpercentgrow(rdate, rdate2)`
基金指定报告期内机构持有市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的机构持有市值占净值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundhsorganpercentgrow(20191231,20181231);
//返回:0.151944943259435
```
### `fundhsothergrow(rdate, rdate2)`
基金指定报告期内其他持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF159919在2014年报的其他持有市值变动(万)
setSysParam(pn_stock(),"OF159919");
return fundhsothergrow(20141231,20131231);
//返回:3206350.87849476
```
### `fundHsOtherPercent(rdate)`
基金指定报告期内其他持有市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF159919在2014年报的其他持有市值占净值比(%)
setSysParam(pn_stock(),"OF159919");
return fundHsOtherPercent(20141231);
//返回:69.9025987572471
```
### `fundHsOtherPercentGrow(rdate, rdate2)`
基金指定报告期内其他持有市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF159919在2014年报的其他持有市值占净值比变动(%)
setSysParam(pn_stock(),"OF159919");
return fundHsOtherPercentGrow(20141231,20131231);
//返回:69.9025987572471
```
### `fundHsOtherValue(rdate)`
基金指定报告期内其他持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF159919在2014年报的其他持有市值(万)
setSysParam(pn_stock(),"OF159919");
return fundHsOtherValue(20141231);
//返回:3206350.87849476
```
### `fundHsPersonGrow(rdate, rdate2)`
基金指定报告期内个人持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的个人持有市值变动(万)
setSysParam(pn_stock(),"OF000001");
return fundHsPersonGrow(20191231,20181231);
//返回:53009.883755893
```
### `fundhspersongrow2(rdate, rdate2)`
基金指定报告期内个人持有份额变动
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报的个人持有份额变动
setSysParam(pn_stock(),"OF000009");
return fundhspersongrow2(20191231,20181231);
//返回:-16431107983.73
```
### `fundhspersonpercent(rdate)`
基金指定报告期内个人持有市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的机构持有市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundhspersonpercent(20191231);
//返回:99.5576381673184
```
### `fundhspersonpercentgrow(rdate, rdate2)`
基金指定报告期内个人持有市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的个人持有市值变动(万)
setSysParam(pn_stock(),"OF000001");
return fundhspersonpercentgrow(20191231,20181231);
//返回:-0.145310022556174
```
### `fundhspersonvalue(rdate)`
基金指定报告期内个人持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报的个人持有市值(万)
setSysParam(pn_stock(),"OF000001");
return fundhspersonvalue(20191231);
//返回:457801.040840455
```
### `fundhspractitionergrow(rdate, rdate2)`
基金指定报告期内从业人员持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的从业人员持有市值变动(万)
setSysParam(pn_stock(),"OF000001");
return fundhspractitionergrow(20191231,20181231);
//返回:-35.813267566
```
### `fundhspractitionergrow2(rdate, rdate2)`
基金指定报告期内从业人员持有份额变动
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报的从业人员持有份额变动
setSysParam(pn_stock(),"OF000009");
return fundhspractitionergrow2(20191231,20181231);
//返回:1889309.58
```
### `fundhspractitionerpercent(rdate)`
基金指定报告期内从业人员持有市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的从业人员持有市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundhspractitionerpercent(20191231);
//返回:0.00131867119665122
```
### `fundhspractitionerpercentgrow(rdate, rdate2)`
基金指定报告期内从业人员持有市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的从业人员持有市值占净值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundhspractitionerpercentgrow(20191231,20181231);
//返回:-0.00899592795489366
```
### `fundhspractitionervalue(rdate)`
基金指定报告期内从业人员持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的从业人员持有市值(万)
setSysParam(pn_stock(),"OF000001");
return fundhspractitionervalue(20191231);
//返回:6.06371402
```
### `fundHsmx(fundid, rdate)`
基金指定报告期持有人结构。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundid` | String | 字符串。基金代码 |
| `rdate` | integer | 整数。指定报告期 |
返回:Array,TableArray
#### 示例
```tsl
return fundHsmx('OF000001',20221231);
结果:
```
### `fundbdbondpercent(rdate, bondid)`
指定债券市值占净值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券市值占净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercent(20191231,"BK190201"); //结果:2.18
```
### `fundbdbondpercent2(rdate, bondid)`
指定债券市值占总值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券市值占总值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercent2(20191231,"190030"); //结果:2.15383767484141
```
### `fundbdbondpercent3(rdate, bondid)`
指定债券市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercent3(20191231,"BK190303"); //结果:10.8004635145045
```
### `fundbdbondpercent5(rdate, bondid)`
指定债券市值占固定收益投资市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券"190303"市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercent5(20191231,"BK190303"); //结果:10.8004635145045
```
### `fundBdBondPercentGrow(rdate, rdate2, bondid)`
指定债券市值占净值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20200331与20191231期间指定债券市值占净值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundBdBondPercentGrow(20200331,20191231,"BK190303");//结果:0.13
```
### `fundbdbondpercentgrow2(rdate, rdate2, bondid)`
指定债券市值占总值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券市值占总值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercentgrow2(20191231,20181231,"BK190303");
//结果:2.15383767484141
```
### `fundbdbondpercentgrow3(rdate, rdate2, bondid)`
指定债券市值占债券市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券市值占债券市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercentgrow3(20191231,20181231,"BK190303");
//结果:10.8004635145045
```
### `fundbdbondpercentgrow4(rdate, rdate2, bondid)`
指定债券市值占固定收益投资市值比变动(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231与20181231期间指定债券市值占固定收益投资市值比变动(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondpercentgrow4(20191231,20181231,"BK190303");
//结果:10.8004635145045
```
### `fundbdbondvalue(rdate, bondid)`
指定债券持有市值,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231指定债券持有市值
setSysParam(pn_stock(),"OF000001");
return fundbdbondvalue(20191231,"BK190303"); //结果:100120000
```
### `fundbdbondvaluegrow(rdate, rdate2, bondid)`
指定债券持有市值变动,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20241231与20231231期间指定债券持有市值变动
setSysParam(pn_stock(),"OF000001");
return fundbdbondvaluegrow(20241231,20231231,"BK101564021"); //结果:-735357.74000001
```
### `fundbdbondvaluegrowratio(rdate, rdate2, bondid)`
指定债券持有市值变比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20200331与20191231期间指定债券持有市值变比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdbondvaluegrowratio(20200331,20191231,"BK190303");
//结果:1.1785856971634
```
### `fundbdbondvolume(rdate, bondid)`
指定债券持有份额,与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231"190303"债券持有份额
setSysParam(pn_stock(),"OF000001");
return fundbdbondvolume(20191231,"BK190303"); //结果:1000000
```
### `fundbdbondvolumegrow(rdate, rdate2, bondid)`
指定债券持有份额变动,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `bondid` | String | 字符串,债券代码 |
返回:REAL
#### 示例
```tsl
// "OF000001"在20210331与20191231期间指定债券持有份额变动
setSysParam(pn_stock(),"OF000001");
return fundbdbondvolumegrow(20210331,20191231,"BK180208"); //结果:200000
```
### `fundbdnonpercent3(rdate, topn)`
第N名债券市值占债券市值比(%),与系统参数证券(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbdnonpercent3(20191231,2); //结果:14.312663785232
```
### `fundbdnonvalue(rdate, topn)`
第N名债券持有市值,与系统参数证券(基金)相关。单位:元
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
// "OF000001"在20191231第2名债券持有市值
setSysParam(pn_stock(),"OF000001");
return fundbdnonvalue(20191231,2); //结果:132678000
```
### `fundBdSumN(rdate, top_n, field)`
前N名债券相关数据,与系统参数(基金)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。前N |
| `field` | String | 字符串。列名 |
返回:Real
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return fundBdSumN(20221231,1,'市值');
//结果:110787178.08
```
### `fundcbbondpercent3(rdate, stockid)`
基金指定报告期指定可转债市值占债券市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报关于SZ128016可转债市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundcbbondpercent3(20191231,"SZ128016");
//返回:0.0583276389158785
```
### `fundcbnonpercent3(rdate, topn)`
基金指定报告期第N名可转债市值占债券市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报第1名可转债市值占债券市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundcbnonpercent3(20191231,1);
//返回:0.0709744876230163
```
### `fundCbQk(fundid, rdate, top_n)`
指定报告期的处于转股期的可转债明细。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundid` | String | 字符串。基金代码 |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。前N |
返回:Array
#### 示例
```tsl
return fundCbQk('OF000001',20231231,1);
结果:
```
### `fundssnetassetvalue(rdate)`
指定报告期基金资产净值(万),与当前证券相关
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报的基金资产净值(万)
setSysParam(pn_stock(),"OF006872");
return fundssnetassetvalue(20191231);
//返回:19402.6657367436
```
### `fundsspurchasevalue(rdate, rdate2)`
指定报告期基金净申购金额(万),与当前证券相关
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报的基金净申购金额(万)
setSysParam(pn_stock(),"OF000001");
return fundsspurchasevalue(20191231,20181231);
//返回:53870.359121009
```
### `fundpmnoncode(rdate, topn)`
基金指定报告期第N名贵金属代码
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:STRING
#### 示例
```tsl
//计算基金OF002610在2019年报第1名贵金属代码
setSysParam(pn_stock(),"OF002610");
return fundpmnoncode(20191231,1);
//返回:Au9999
```
### `fundpmsecuritypercentgrow3(rdate, rdate2, stockid)`
基金指定报告期指定贵金属市值占贵金属市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF002610在2019年报Au9999市值占贵金属市值比变动(%)
setSysParam(pn_stock(),"OF002610");
return fundpmsecuritypercentgrow3(20191231,20181231,"Au9999");
//返回:86.9249617151608
```
### `fundpmsumnpercent2(rdate, topn)`
基金指定报告期前N名贵金属市值占总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF002610在2019年报前1名贵金属市值占总值比(%)
setSysParam(pn_stock(),"OF002610");
return fundpmsumnpercent2(20191231,1);
//返回:0.00341047340700451
```
### `fundpmsumnpercent3(rdate, topn)`
基金指定报告期前N名贵金属市值占贵金属市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF002610在2019年报前1名贵金属市值占贵金属市值比(%)
setSysParam(pn_stock(),"OF002610");
return fundpmsumnpercent3(20191231,1);
//返回:100
```
### `fundpmsumnvaluegrowratio(rdate, rdate2, topn)`
基金指定报告期前N名贵金属持有市值变比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF002610在2019年报前1名贵金属持有市值变比(%)
setSysParam(pn_stock(),"OF002610");
return fundpmsumnvaluegrowratio(20191231,20181231,1);
//返回:-81.9879496846482
```
### `fundfdfundpercent2(rdate, stockid)`
基金指定报告期指定基金市值占总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,基金代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报关于OF003349的市值占总值比(%)
setSysParam(pn_stock(),"OF006872");
return fundfdfundpercent2(20191231,"OF003349");
//返回:11.016283621239
```
### `fundfdfundpercent3(rdate, stockid)`
基金指定报告期指定基金市值占基金市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,基金代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报关于OF003349的市值占基金市值比(%)
setSysParam(pn_stock(),"OF006872");
return fundfdfundpercent3(20191231,"OF003349");
//返回:15.6340847701839
```
### `fundfdfundpercentgrow2(rdate, rdate2, stockid)`
基金指定报告期指定基金市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,基金代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF005809在2019年报关于OF004496的市值占总值比变动(%)
setSysParam(pn_stock(),"OF005809");
return fundfdfundpercentgrow2(20191231,20181231,"OF004496");
//返回:15.6386901861466
```
### `fundfdfundpercentgrow3(rdate, rdate2, stockid)`
基金指定报告期指定基金市值占基金市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,基金代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF005809在2019年报关于OF004496的市值占总值比变动(%)
setSysParam(pn_stock(),"OF005809");
return fundfdfundpercentgrow3(20191231,20181231,"OF004496");
//返回:16.7501100284876
```
### `fundfdfundvaluegrowratio(rdate, rdate2, stockid)`
基金指定报告期指定基金持有市值变比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,基金代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000008在2019年报关于OF159922的持有市值变比(%)
setSysParam(pn_stock(),"OF000008");
return fundfdfundvaluegrowratio(20191231,20181231,"OF159922");
//返回:147.794380361061
```
### `fundfdmanagerpercent3(rdate)`
持有关联基金市值占基金市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报持有关联基金占基金市值比(%)
setSysParam(pn_stock(),"OF006872");
return fundfdmanagerpercent3(20191231);
//返回:29.05
```
### `fundbsstocknetamount(rdate, stockid)`
基金指定报告期的指定股票累计净买入金额(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报关于SZ300760累计净买入金额(万)
setSysParam(pn_stock(),"OF006872");
return fundbsstocknetamount(20191231,"SZ300760");
//返回:6.1258
```
### `fundbsstocksellamount(rdate, stockid)`
指定股票累计卖出金额(万),基金指定报告期的指定股票累计卖出金额(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF006872在2019年报关于SZ300760累计卖出金额(万)
setSysParam(pn_stock(),"OF006872");
return fundbsstocksellamount(20191231,"SZ300760");
//返回:300.9683
```
### `fundbsstocksellpercent2(rdate, stockid)`
基金指定报告期的指定股票累计卖出金额占期初总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报关于SH601336累计卖出金额占期初总值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbsstocksellpercent2(20191231,"SH601336");
//返回:12.9206133999664
```
### `fundbsstocksellpercent3(rdate, stockid)`
基金指定报告期的指定股票累计卖出金额占期初股票市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报关于SH601336累计卖出金额占期初股票市值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbsstocksellpercent3(20191231,"SH601336");
//返回:21.0911411411508
```
### `fundbsstocksellrank(rdate, stockid)`
基金指定报告期的指定股票累计卖出排名
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
计算基金OF006872在2019年报关于SZ300760累计卖出排名
setSysParam(pn_stock(),"OF006872");
return fundbsstocksellrank(20191231,"SZ300760");
//返回:2
```
### `fundbssumnbuypercent(rdate, topn)`
基金指定报告期的前N名股票累计买入金额占期初净值比(%);
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报前3名股票累计买入金额占期初净值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbssumnbuypercent(20191231,3);
//返回:36.24
```
### `fundbssumnsellpercent2(rdate, topn)`
基金指定报告期的前N名股票累计卖出金额占期初总值比(%);
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N,当TopN=0或者TopN为空时表示所有股票累计买入金额(万) |
返回:REAL
#### 示例
```tsl
//计算基金OF000001在2019年报前3名股票累计卖出金额占期初总值比(%)
setSysParam(pn_stock(),"OF000001");
return fundbssumnsellpercent2(20191231,3);
//返回:36.0979897363215
```
### `fundarmasset(rdate)`
基金指定报告期各期限资产合计(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报资产(万)
setSysParam(pn_stock(),"OF000009");
return fundarmasset(20191231);
//返回:4490211.90392788
```
### `fundarmasset120Dpercent(rdate)`
基金指定报告期90天(含)-120天资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报90天(含)-120天资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmasset120Dpercent(20191231);
//返回:4.07
```
### `fundarmasset30Dpercent(rdate)`
基金指定报告期30天以内资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报30天以内资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmasset30Dpercent(20191231);
//返回:18.99
```
### `fundarmasset397D(rdate)`
基金指定报告期120天(含)-397天(含)资产(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报120天(含)-397天(含)资产(万)
setSysParam(pn_stock(),"OF000009");
return fundarmasset397D(20191231);
//返回:1160105.40761802
```
### `fundarmasset397Dpercent(rdate)`
基金指定报告期120天(含)-397天(含)资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报120天(含)-397天(含)资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmasset397Dpercent(20191231);
//返回:29.58
```
### `fundarmasset60D(rdate)`
基金指定报告期30天(含)-60天资产(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报30天(含)-60天资产(万)
setSysParam(pn_stock(),"OF000009");
return fundarmasset60D(20191231);
//返回:568286.928883876
```
### `fundarmasset60Dpercent(rdate)`
基金指定报告期30天(含)-60天资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报30天(含)-60天资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmasset60Dpercent(20191231);
//返回:14.49
```
### `fundarmasset90D(rdate)`
基金指定报告期60天(含)-90天资产(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报60天(含)-90天资产(万)
setSysParam(pn_stock(),"OF000009");
return fundarmasset90D(20191231);
//返回:1857815.86067834
```
### `fundarmasset90Dpercent(rdate)`
基金指定报告期60天(含)-90天资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报60天(含)-90天资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmasset90Dpercent(20191231);
//返回:47.37
```
### `fundarmassetpercent(rdate)`
基金指定报告期资产占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmassetpercent(20191231);
//返回:114.49
```
### `fundarmdebt(rdate)`
基金指定报告期各期限负债合计(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报负债(万)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt(20191231);
//返回:614173.45109189
```
### `fundarmdebt120D(rdate)`
基金指定报告期90天(含)-120天负债(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报90天(含)-120天负债(万)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt120D(20191231);
//返回:0
```
### `fundarmdebt120Dpercent(rdate)`
基金指定报告期90天(含)-120天负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报90天(含)-120天负债占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt120Dpercent(20191231);
//返回:0
```
### `fundarmdebt30D(rdate)`
基金指定报告期30天以内负债(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报30天以内负债(万)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt30D(20191231);
//返回:614173.45109189
```
### `fundarmdebt30Dpercent(rdate)`
基金指定报告期30天以内负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报30天以内资产占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt30Dpercent(20191231);
//返回:15.66
```
### `fundarmdebt397D(rdate)`
基金指定报告期120天(含)-397天(含)负债(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报120天(含)-397天(含)负债(万)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt397D(20191231);
//返回:0
```
### `fundarmdebt397Dpercent(rdate)`
基金指定报告期120天(含)-397天(含)负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报120天(含)-397天(含)负债占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt397Dpercent(20191231);
//返回:0
```
### `fundarmdebt60D(rdate)`
基金指定报告期30天(含)-60天负债(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF004185在2018年中报30天(含)-60天负债(万)
setSysParam(pn_stock(),"OF004185");
return fundarmdebt60D(20180630);
//返回:2003.2
```
### `fundarmdebt60Dpercent(rdate)`
基金指定报告期30天(含)-60天负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF004185在2018年中报30天(含)-60天负债占净值比(%)
setSysParam(pn_stock(),"OF004185");
return fundarmdebt60Dpercent(20180630);
//返回:2.58
```
### `fundarmdebt90D(rdate)`
基金指定报告期60天(含)-90天负债(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报60天(含)-90天负债(万)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt90D(20191231);
//返回:0
```
### `fundarmdebt90Dpercent(rdate)`
基金指定报告期60天(含)-90天负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报60天(含)-90天负债占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmdebt90Dpercent(20191231);
//返回:0
```
### `fundarmdebtpercent(rdate)`
基金指定报告期负债占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报负债占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundarmdebtpercent(20191231);
//返回:15.66
```
### `fundArmmx(fundid, rdate, dtype)`
指定报告期的平均剩余期限分布情况。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundid` | String | 字符串。基金代码 |
| `rdate` | Integer | 整数。指定报告期 |
| `dtype` | Integer | 用户自定义。分布情况,取值如下: |
返回:Array
#### 示例
```tsl
return fundArmmx('OF000009',20231231,0);
结果:
```
### `fundArmAssetByField(fundid, rdate, dtype, value_field)`
指定报告期的平均剩余期限分布情况计算资产或负债。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundid` | String | 字符串。基金代码 |
| `rdate` | Integer | 整数。指定报告期 |
| `dtype` | Integer | 用户自定义。分布类型,取值如下: |
| `value_field` | String | 字符串。指定字段 |
返回:Real
#### 示例
```tsl
return fundArmAssetByField('OF000009',20231231,1,'各期限资产占净值比例(%)');
//结果:558753.59
```
### `fundabsnoncode(rdate, topn)`
基金指定报告期第N名资产支持证券代码
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:STRING
#### 示例
```tsl
计算基金OF000009在2019年报第3名资产支持证券代码
setSysParam(pn_stock(),"OF000009");
return fundabsnoncode(20191231,3);
//返回:SZ139435
```
### `fundabsnonpercent(rdate, topn)`
基金指定报告期第N名资产支持证券市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报第3名资产支持证券市值占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabsnonpercent(20191231,3);
//返回:0.13
```
### `fundabsnonpercent2(rdate, topn)`
基金指定报告期第N名资产支持证券市值占总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报第3名资产支持证券市值占总值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabsnonpercent2(20191231,3);
//返回:0.110046329631174
```
### `fundabsnonpercent3(rdate, topn)`
基金指定报告期第N名资产支持证券市值占固定收益投资市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报第3名资产支持证券市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabsnonpercent3(20191231,3);
//返回:0.212776017382555
```
### `fundabsnonpercent4(rdate, topn)`
基金指定报告期第N名资产支持证券市值占资产支持证券市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报第3名资产支持证券市值占资产支持证券市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabsnonpercent4(20191231,3);
//返回:4.56202664893526
```
### `fundabsnonvalue(rdate, topn)`
基金指定报告期第N名资产支持证券持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报第3名资产支持证券持有市值(万)
setSysParam(pn_stock(),"OF000009");
return fundabsnonvalue(20191231,3);
//返回:5000
```
### `fundabsnonvolume(rdate, topn)`
基金指定报告期第N名资产支持证券持有份额
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,第N |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报第3名资产支持证券持有份额
setSysParam(pn_stock(),"OF000009");
return fundabsnonvolume(20191231,3);
//返回:500000
```
### `fundabssecuritypercent(rdate, stockid)`
基金指定报告期指定资产支持证券市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercent(20191231,"SZ139453");
//返回:0.18
```
### `fundabssecuritypercent2(rdate, stockid)`
基金指定报告期指定资产支持证券市值占总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占总值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercent2(20191231,"SZ139453");
//返回:0.154064861483644
```
### `fundabssecuritypercent3(rdate, stockid)`
基金指定报告期指定资产支持证券市值占固定收益投资市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercent3(20191231,"SZ139453");
//返回:0.297886424335576
```
### `fundabssecuritypercent4(rdate, stockid)`
基金指定报告期指定资产支持证券市值占资产支持证券市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占资产支持证券市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercent4(20191231,"SZ139453");
//返回:6.38683730850936
```
### `fundabssecuritypercentgrow(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占净值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercentgrow(20191231,20181231,"SZ139453");
//返回:0.18
```
### `fundabssecuritypercentgrow2(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占总值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercentgrow2(20191231,20181231,"SZ139453");
//返回:0.154064861483644
```
### `fundabssecuritypercentgrow3(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券市值占固定收益投资市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占固定收益投资市值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercentgrow3(20191231,20181231,"SZ139453");
//返回:0.297886424335576
```
### `fundabssecuritypercentgrow4(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券市值占资产支持证券市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券市值占资产支持证券市值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecuritypercentgrow4(20191231,20181231,"SZ139453");
//返回:6.38683730850936
```
### `fundabssecurityvalue(rdate, stockid)`
基金指定报告期指定资产支持证券持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券持有市值(万)
setSysParam(pn_stock(),"OF000009");
return fundabssecurityvalue(20191231,"SZ139453");
//返回:7000
```
### `fundabssecurityvaluegrow(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券持有市值变动(万)
setSysParam(pn_stock(),"OF000009");
return fundabssecurityvaluegrow(20191231,20181231,"SZ139453");
//返回:7000
```
### `fundabssecurityvaluegrowratio(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券持有市值变比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报关于SZ139453资产支持证券持有市值变比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssecurityvaluegrowratio(20191231,20181231,"SZ139453");
//返回:0
```
### `fundabssecurityvolume(rdate, stockid)`
基金指定报告期指定资产支持证券持有份额
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报关于SZ139453资产支持证券持有份额
setSysParam(pn_stock(),"OF000009");
return fundabssecurityvolume(20191231,"SZ139453");
//返回:700000
```
### `fundabssecurityvolumegrow(rdate, rdate2, stockid)`
基金指定报告期指定资产支持证券持有份额变动
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `stockid` | String | 字符串,股票代码 |
返回:REAL
#### 示例
```tsl
计算基金OF000009在2019年报关于SZ139453资产支持证券持有份额变动
setSysParam(pn_stock(),"OF000009");
return fundabssecurityvolumegrow(20191231,20181231,"SZ139453");
//返回:700000
```
### `fundabssumnpercent(rdate, topn)`
基金指定报告期前N名资产支持证券市值占净值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占净值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercent(20191231,3);
//返回:0.44
```
### `fundabssumnpercent2(rdate, topn)`
基金指定报告期前N名资产支持证券市值占总值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占总值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercent2(20191231,3);
//返回:0.374157520745991
```
### `fundabssumnpercent3(rdate, topn)`
基金指定报告期前N名资产支持证券市值占固定收益投资市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占固定收益投资市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercent3(20191231,3);
//返回:0.723438459100685
```
### `fundabssumnpercent4(rdate, topn)`
基金指定报告期前N名资产支持证券市值占资产支持证券市值比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占资产支持证券市值比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercent4(20191231,3);
//返回:15.5108906063799
```
### `fundabssumnpercentgrow(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券市值占净值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占净值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercentgrow(20191231,20181231,3);
//返回:0.33
```
### `fundabssumnpercentgrow2(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券市值占总值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占总值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercentgrow2(20191231,20181231,3);
//返回:0.267815386984316
```
### `fundabssumnpercentgrow3(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券市值占固定收益投资市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占固定收益投资市值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercentgrow3(20191231,20181231,3);
//返回:0.470090300029519
```
### `fundabssumnpercentgrow4(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券市值占资产支持证券市值比变动(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券市值占资产支持证券市值比变动(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnpercentgrow4(20191231,20181231,3);
//返回:-84.4891093936201
```
### `fundabssumnvalue(rdate, topn)`
基金指定报告期前N名资产支持证券持有市值(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券持有市值(万)
setSysParam(pn_stock(),"OF000009");
return fundabssumnvalue(20191231,3);
//返回:17000
```
### `fundabssumnvaluegrow(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券持有市值变动(万)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券持有市值变动(万)
setSysParam(pn_stock(),"OF000009");
return fundabssumnvaluegrow(20191231,20181231,3);
//返回:8700
```
### `fundabssumnvaluegrowratio(rdate, rdate2, topn)`
基金指定报告期前N名资产支持证券持有市值变比(%)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `rdate` | Integer | 整型,指定报告期 |
| `rdate2` | Integer | 整型,同比报告期 |
| `topn` | Integer | 整型,前N |
返回:REAL
#### 示例
```tsl
//计算基金OF000009在2019年报前3名资产支持证券持有市值变比(%)
setSysParam(pn_stock(),"OF000009");
return fundabssumnvaluegrowratio(20191231,20181231,3);
//返回:104.819277108434
```
### `fundAbsQk(fundid, rdate, top_n)`
指定报告期的资产支持证券明细。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `fundid` | String | 字符串。基金代码 |
| `rdate` | Integer | 整数。指定报告期 |
| `top_n` | Integer | 整数。前N |
返回:Array
#### 示例
```tsl
return fundAbsQk('OF000379',20191231,3);
结果:
```
### `isFundDeclareIr(r_date)`
报告期是否已公布投资组合,与系统参数(证券代码)相关。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `r_date` | Integer | 整数。报告期 |
返回:Integer
#### 示例
```tsl
setSysParam(PN_Stock(),'OF000001');
return isFundDeclareIr(20221231);
```
### `fundsChangeInFairValueOfFinancialAssetBond(fund_arr, r_date)`
获得指定报告期基金列表债券投资变动收益
| 参数 | 类型 | 说明 |
| ---------- | -------- | ----------------------- |
| `fund_arr` | array | 一维字符串数组,基金列表 |
| `r_date` | datetime | 报告期,指定报告期 |
返回:array
### `fundsChangeInFairValueOfFinancialAssetStock(fund_arr, r_date)`
获得指定报告期基金列表股票投资变动收益
| 参数 | 类型 | 说明 |
| ---------- | -------- | ----------------------- |
| `fund_arr` | array | 一维字符串数组,基金列表 |
| `r_date` | datetime | 报告期,指定报告期 |
返回:array
### `fundScDominatorValue()`
基金持股-单位。根据数据库提供商返回对应的值
返回:any
### `fundScPercentageField()`
基金持股-占净值比例。根据数据库提供商返回对应的值
返回:string
### `fundScStockCodeField()`
基金持股-股票代码。根据数据库提供商返回对应的值
返回:string
### `fundScMarketValueField()`
基金持股-市值。根据数据库提供商返回对应的值
返回:string
### `fundScStockNameField()`
基金持股-投资股票名称。根据数据库提供商返回对应的值
返回:string
### `fundScHoldAmountField()`
基金持股-持有数量。根据数据库提供商返回对应的值
返回:string
### `fundBcStockCodeField()`
持债明细-债券代码。根据数据库提供商返回对应的值
返回:string
### `fundBcHoldAmountField()`
持债明细-持有数量。根据数据库提供商返回对应的值
返回:string
### `fundBcMaturityField()`
持债明细-偿还期限。根据数据库提供商返回对应的值
返回:string
### `fundBcTypeField()`
持债明细-转股期。根据数据库提供商返回对应的值
返回:string
### `fundBcMarketValueField()`
持债明细-市值。根据数据库提供商返回对应的值
返回:string
### `fundBcNoField()`
持债明细-名次。根据数据库提供商返回对应的值
返回:string
### `fundBcStockNameField()`
持债明细-债券名称。根据数据库提供商返回对应的值
返回:string
### `fundBcPercentageField()`
持债明细-占净值比例。根据数据库提供商返回对应的值
返回:string
### `fundBcDominatorValue()`
持债明细-单位。根据数据库提供商返回对应的值
返回:any
### `fundScsTypeField()`
累计买/卖出超净值2%-变动类型。根据数据库提供商返回对应的值
返回:string
### `fundScb2CharacterField()`
累计买入超净值2%-类型。根据数据库提供商返回对应的值
返回:string
### `fundScb2StockNameField()`
累计买入超净值2%-股票名称。根据数据库提供商返回对应的值
返回:string
### `fundScb2AmountField()`
累计买入超净值2%-累计买入金额。根据数据库提供商返回对应的值
返回:string
### `fundScb2PercentageField()`
累计买入超净值2%-占期初基金资产净值比例。根据数据库提供商返回对应的值
返回:string
### `fundScb2DominatorValue()`
累计买入超净值2%-单位。根据数据库提供商返回对应的值
返回:any
### `fundScb2StockCodeField()`
累计买入超净值2%-股票代码。根据数据库提供商返回对应的值
返回:string
### `fundScs2AmountField()`
累计卖出超净值2%-累计卖出金额。根据数据库提供商返回对应的值
返回:string
### `fundScs2PercentageField()`
累计卖出超净值2%-占期初基金资产净值比例。根据数据库提供商返回对应的值
返回:string
### `fundScs2StockCodeField()`
累计卖出超净值2%-股票代码。根据数据库提供商返回对应的值
返回:string
### `fundScs2StockNameField()`
累计卖出超净值2%-股票名称。根据数据库提供商返回对应的值
返回:string
### `fundScs2CharacterField()`
累计卖出超净值2%-类型。根据数据库提供商返回对应的值
返回:string
### `fundScs2DominatorValue()`
累计卖出超净值2%-单位。根据数据库提供商返回对应的值
返回:any
### `fundIcDominatorValue()`
行业配置-单位。根据数据库提供商返回对应的值
返回:any
### `fundIcMarketValueField()`
基金行业投资-市值。根据数据库提供商返回对应的值
返回:string
### `fundIcPercentageField()`
基金行业投资-占基金资产净值比例。根据数据库提供商返回对应的值
返回:string
### `portfolioHvByPe(bk_name, beg_t, end_t, money, adjust_month, from_no, to_no, percent_type, return_type)`
按市盈率进行投资组合校验,算法如下:计算起始日样本股的市盈率,按照升序排序。对于市盈率<0的股票,不予考虑;取指定索引段(如:取市盈率排名的FromNo - ToNo名的)股票作为投资组合股票,按照流通股加权/总股本加权/等资金加权等方式确定投资组合每个股票的投资比例,计算投资组合股票每日市值,并和指数进行比较
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `bk_name` | String | 字符串,样本股 |
| `beg_t` | TDateTime | 日期型时间,投资开始日 |
| `end_t` | TDateTime | 日期型时间,投资截止日 |
| `money` | Real | 实数,投资金额(万) |
| `adjust_month` | Integer | 整数,投资组合调整时段(月) |
| `from_no` | Integer | 整数,样本股选择开始编号 |
| `to_no` | Integer | 整数,样本股选择截止编号 |
| `percent_type` | Integer | 用户自定义,投资比例选择,含义如下表: |
| `return_type` | | 用户自定义,返回类型,0表示返回图形,1表示数据 |
返回:TableArray
#### 示例
```tsl
return portfolioHvByPe("深证A股;上证A股",intToDate(20120912),intToDate(20121022),500,3,1,10,2,1);
//结果:
```
### `portfolioTrack(zh_result, tmoney, beg_t, end_t)`
对已经建立好的投资组合进行跟踪
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `zh_result` | Array | 数据表,组合结果,数据格式如下: |
| `tmoney` | Real | 实数,总共投资金额<万元> |
| `beg_t` | TDateTime | 日期型时间,开始投资日期 |
| `end_t` | TDateTime | 日期型时间,结束投资日期 |
返回:TableArray
#### 示例
```tsl
return portfolioTrack("Data",500,intToDate(20120721),intToDate(20121022));
//结果:
```
### `portfolioByAny(stock_arr, end_t, eval_exp, sort_dir, range_type, range_beg, range_end, condition)`
计算满足条件Condition的股票的EvalExp,选取值在RangeBeg跟RangeEnd之间,按照不同的RangeType类型选择
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `stock_arr` | TableArray | 数据表,股票列表,必须含有’代码’,’股数’ |
| `end_t` | TDateTime | 日期型时间,当前时间 |
| `eval_exp` | Expression | 表达式 |
| `sort_dir` | Boolean | 真假,排序方向 |
| `range_type` | Integer | 整数,范围类型 |
| `range_beg` | Real | 实数,范围上限 |
| `range_end` | Real | 实数,范围下限 |
| `condition` | Expression | 表达式,条件选择 |
返回:TableArray
#### 示例
```tsl
return portfolioByAny(
array("SH600718","SZ000920"),
intToDate(20120916),
@open(),
1,0,7,8,@true);
//结果:
```
### `portfolioTrackingByAny(bk_name, stock_arr, beg_t, end_t, adjust_days, eval_exp, sort_dir, range_type, range_beg, range_end, condition)`
得出投资组合中的一些中间结果数据
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `bk_name` | String | 字符串,板块名称 |
| `stock_arr` | TableArray | 数据表,股票列表,必须含有’代码’,’股数’ |
| `beg_t` | TDateTime | 日期型时间,起始日期 |
| `end_t` | TDateTime | 日期型时间,当前时间 |
| `adjust_days` | Integer | 整数 |
| `eval_exp` | Expression | 表达式 |
| `sort_dir` | Boolean | 真假,排序方向 |
| `range_type` | Integer | 整数,范围类型 |
| `range_beg` | Real | 实数,范围上限 |
| `range_end` | Real | 实数,范围下限 |
| `condition` | Expression | 表达式,条件选择 |
返回:得出投资组合中的一些中间结果数据
#### 示例
```tsl
stock_arr:=array(('代码':"SH600718",'股数':20),('代码':"SZ000920",'股数':30));
begt:=intToDate(20121018);
endt:=intToDate(20121026);
return portfolioTrackingByAny(
"深证A股;上证A股",
StockArr,
begt,
endt,
3,
@stockZf3(),
false,
0,0,10,@true);
//结果:
```
### `portfolioByPe(stock_arr, end_t, from_no, to_no)`
根据FromNoToNo取StockArr在EndT的市盈率升序后的结果集。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `stock_arr` | String | 字符串,板块名称 |
| `end_t` | TDateTime | 日期型时间,开始时间 |
| `from_no` | integer | 整数,起始行号 |
| `to_no` | integer | 整数,截止行号 |
返回:Array,TableArray
#### 示例
```tsl
stock_arr:=array("SH600718","SZ000920","SH600000");
end_t:=intToDate(20120828);
return portfolioByPe(stock_arr,end_t,1,2);
//结果:
```
### `portfolioGraph(t)`
组合收盘和指数收盘的图。
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `t` | TableArray | 数据表,包含’日期’,’组合指数’与’指数’字段的表 |
返回:TableArray
#### 示例
```tsl
setSysParam(PN_DATE(),intToDate(20121029));
t:=nDay(100,'日期',sp_time(),'指数',spec(close(),'SZ000002'),'组合指数',spec(close(),'SZ000001'));
return portfolioGraph(t);
//结果:
```
### `portfolioPercent(stock_arr, beg_t, money, percent_type)`
按照不同投资比例下的股票所分配的资金以及所购买股数
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `stock_arr` | Array | |
| `beg_t` | | |
| `money` | | |
| `percent_type` | | |
返回:Array,TableArray
#### 示例
```tsl
stock_arr:=array("SH600718","SZ000920");
endt:=intToDate(20120918);
return portfolioPercent(stock_arr,endt,500,0);
//结果:
```
### `portfolioTracking(bk_name, stock_arr, beg_t, end_t, adjust_month, from_no, to_no)`
跟踪股票组合的每日组合市值,涨幅,累计涨幅与当前环境下的指数的相关数据比较
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `bk_name` | | |
| `stock_arr` | | |
| `beg_t` | | |
| `end_t` | | |
| `adjust_month` | | |
| `from_no` | | |
| `to_no` | | |
返回:Array,TableArray
#### 示例
```tsl
stock_arr:=array(('代码':'SZ000002','股数':10),('代码':'SH600000','股数':30),('代码':'SZ000001','股数':20));
begt:=intToDate(20120912);
endt:=intToDate(20121022);
return portfolioTracking('沪深300',stock_arr,begt,endt,4,2,5);
//结果:
```
### `fundPfHoldFeelingStat(fund_id, begt, endt, roll_n_year_arr)`
固定持有期收益统计 区间内,任意时点买入持有固定期限(年),统计任意时点对应的持有收益表现 暂仅支持整年度持有期
| 参数 | 类型 | 说明 |
| ----------------- | -------- | ------------------------------- |
| `fund_id` | string | 证券,代码 |
| `begt` | datetime | 日期,开始日 |
| `endt` | datetime | 日期,截止日 |
| `roll_n_year_arr` | array | 一维数字数组,滚动持有期数(年) |
返回:array
### `fundPfHoldFeelingTrend(fund_id, begt, endt, ma_num, delta)`
功能:趋势收益描述
| 参数 | 类型 | 说明 |
| --------- | -------- | --------------- |
| `fund_id` | string | 证券,代码 |
| `begt` | datetime | 日期,开始日 |
| `endt` | datetime | 日期,截止日 |
| `ma_num` | any | 整数,均线值 |
| `delta` | any | 整数,路程间隔数 |
返回:array
### `fundPfHoldFeeling(fund_id, begt, end_t, cycle, ma_num, delta, roll_years_arr)`
基金持有体验指标
| 参数 | 类型 | 说明 |
| ---------------- | -------- | ------------------------------------------ |
| `fund_id` | string | 字符串类型,基金代码 |
| `begt` | datetime | 日期类型,开始日 |
| `end_t` | datetime | 日期类型,截止日 |
| `cycle` | string | 字符串类型,取数周期 |
| `ma_num` | any | 整数类型,移动期数 |
| `delta` | any | 整数类型,路程间隔数 |
| `roll_years_arr` | array | 一维数组类型,滚动年份数,例如array(1,3,5) |
返回:array
### `fundPfThemeStyle(fund_id, beg_t, end_t, theme_arr, top_n)`
主题风格因子:基于业绩
| 参数 | 类型 | 说明 |
| ----------- | -------- | ------------------------------------------------------------------------------------------------------------------ |
| `fund_id` | string | 字符串类型,基金代码 |
| `beg_t` | datetime | 日期类型,开始日 |
| `end_t` | datetime | 日期类型,截止日 |
| `theme_arr` | array | 数据表类型,主题池,需包含"主题"、"代表指数"及"成分股"字段,;其中,成分股为一维字符串数组,为空时会选择默认主题池 |
| `top_n` | any | 整数类型,前N个主题 |
返回:array
### `fundPfHurst(fundid, begt, endt, cycle)`
Fund_PF_Hurst 相关函数。
| 参数 | 类型 | 说明 |
| -------- | -------- | -------------------- |
| `fundid` | string | 字符串类型,基金代码 |
| `begt` | datetime | 日期类型,区间开始日 |
| `endt` | datetime | 日期类型,区间截止日 |
| `cycle` | any | 周期类型,周期 |
返回:float
### `fundPfCpr(fundid, begt, endt, cycle, index_id)`
Fund_PF_CPR 相关函数。
| 参数 | 类型 | 说明 |
| ---------- | -------- | ------------------------ |
| `fundid` | string | 字符串类型,基金代码 |
| `begt` | datetime | 日期类型,区间开始日 |
| `endt` | datetime | 日期类型,区间截止日 |
| `cycle` | any | 周期类型,周期 |
| `index_id` | string | 字符串类型,基准指数代码 |
返回:float
### `fundAbsHoldDetail(show_number, unit_type, report_date_show_order)`
资产支持证券明细
| 参数 | 类型 | 说明 |
| ------------------------ | ---- | ------------------- |
| `show_number` | any | 用户自定义,显示个数 |
| `unit_type` | any | 用户自定义,显示单位 |
| `report_date_show_order` | bool | object |
返回:bool
### `fundPfFormatData1(fund_id, rdatearr, infoid)`
标准化数据(资产配置) Infoid:322,资产配置表
| 参数 | 类型 | 说明 |
| ---------- | ------ | --------------------- |
| `fund_id` | string | 证券,基金代码 |
| `rdatearr` | array | 数据表类型,报告期列表 |
| `infoid` | any | 整数,表ID |
返回:array
### `fundPfGetTrueFundId(fund_id)`
获取取数代码
| 参数 | 类型 | 说明 |
| --------- | ------ | ------------- |
| `fund_id` | string | 证券,基金代码 |
返回:array
### `fundPfHeadLineConfig()`
字段显示配置
返回:array
### `fundPfFundHoldingValuePercent(endt, holdingvalue)`
基金持基市值占基金规模比例
| 参数 | 类型 | 说明 |
| -------------- | ----- | --------------------- |
| `endt` | any | 整数,截止日 |
| `holdingvalue` | float | 实数,基金个基持基市值 |
返回:float
### `fundPfFormatData3(fund_id, rdatearr, infoid)`
标准化数据(集中度) 市值、集中度:不够前N按最大算。
| 参数 | 类型 | 说明 |
| ---------- | ------ | --------------------- |
| `fund_id` | string | 证券,基金代码 |
| `rdatearr` | array | 数据表类型,报告期列表 |
| `infoid` | any | 整数,表ID |
返回:array
### `fundPfHoldingDetailExprConfig()`
持仓明细表达式配置
返回:array
### `fundPfFormatData2(fund_id, rdatearr, infoid)`
标准化数据(债券/行业配置) Infoid:340,债券配置表; 320,行业配置表
| 参数 | 类型 | 说明 |
| ---------- | ------ | --------------------- |
| `fund_id` | string | 证券,基金代码 |
| `rdatearr` | array | 数据表类型,报告期列表 |
| `infoid` | any | 整数,表ID |
返回:array
### `fundPfAllocation(fund_id, rdatearr, inptype, displaytype, altype)`
配置/走势计算 Inptype控制占比类型,0为占净值比例,1为占总值比例 Displaytype控制是否变比显示,0为不显示,1为显示 Altype控制资产类型,0:资产配置,1:债券配置,2:行业配置,3:债券集中度,4:行业集中度
| 参数 | 类型 | 说明 |
| ------------- | ------ | --------------------- |
| `fund_id` | string | 证券,基金代码 |
| `rdatearr` | array | 数据表类型,报告期列表 |
| `inptype` | any | 整数,占比算法 |
| `displaytype` | bool | object |
| `altype` | any | 整数,资产类型 |
返回:array
### `fundPfBasicConfig()`
基础配置 基础字段的配置:单位、行业类别(申万、中证、证监会)、精度、占比前N 、集中度前N列表
返回:array
### `fundPfAllocationConfig(id)`
配置表字段配置
| 参数 | 类型 | 说明 |
| ---- | ---- | ------------- |
| `id` | any | 整数,字段配置 |
返回:array
### `fundPfBondHoldingValuePercent(endt, holdingvalue)`
基金持债数量占发行量比例
| 参数 | 类型 | 说明 |
| -------------- | ----- | --------------------- |
| `endt` | any | 整数,截止日 |
| `holdingvalue` | float | 实数,基金个券持债张数 |
返回:float
### `fundPfHoldingDetailConfig()`
持仓明细配置
返回:array
### `fundPfhbCalculation(data, hbdata, infoid)`
计算变比数据 同比数据占比-上一个报告期数据占比=变比 集中度:不够前N或者上期不够前N,视为不可比,赋'-'
| 参数 | 类型 | 说明 |
| -------- | ----- | ----------------------- |
| `data` | array | 数据表类型,配置数据 |
| `hbdata` | array | 数据表类型,环比配置数据 |
| `infoid` | any | 整数,表ID |
返回:array
### `fundsCwcs(end_t, n_days)`
返回开放式基金在指定日的仓位测算数据。
| 参数 | 类型 | 说明 |
| -------- | -------- | -------------------- |
| `end_t` | datetime | 日期类型,截止日期 |
| `n_days` | any | 整数,回归所用交易点 |
返回:array
### `fundHoldConfiguration2(info_id)`
投资组合-持仓明细指标配置信息
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `info_id` | Integer | 整数,表ID |
返回:Array
### `fundHoldConfiguration(info_id)`
(参考文档未提供简述。)
| 参数 | 类型 | 说明 |
| --- | --- | --- |
| `info_id` | Integer | 整数,表ID |
返回:any
### `fundiccentralizationCall(fund_arr, r_date, sort_by, sort_order, return_number)`
基金行业集中度。
| 参数 | 类型 | 说明 |
| --------------- | -------- | -------------------------------------- |
| `fund_arr` | array | 数组。基金列表。 |
| `r_date` | datetime | 整数。报告期。 |
| `sort_by` | string | 字符串。排序字段,取值如下: |
| `sort_order` | any | 整数。排序方法,1表示正序,0表示逆序。 |
| `return_number` | any | 整数。返回个数。 |
返回:array
### `fundsCurrencyNetAsset(bk_name, end_t, sort_by, sort_order, return_number)`
返回指定板块指定日期货币基金净值对比数据。
| 参数 | 类型 | 说明 |
| --------------- | -------- | -------------------- |
| `bk_name` | string | 字符串类型,板块名称 |
| `end_t` | datetime | 日期类型,截止日期 |
| `sort_by` | any | 整型,排序字段 |
| `sort_order` | any | 整型,排序方式 |
| `return_number` | any | 整型,返回个数 |
返回:array
### `fundsConvBondHoldDetail(bk_name, rdate, top_n)`
可转债明细
| 参数 | 类型 | 说明 |
| --------- | -------- | ------------------- |
| `bk_name` | string | 市场和板块,板块名称 |
| `rdate` | datetime | 报告期,报告期 |
| `top_n` | any | 用户自定义,取前N名 |
返回:bool
### `fundsCumBuyAndSell(bk_name, rdate, top_n, unit_type)`
累计买入和卖出
| 参数 | 类型 | 说明 |
| ----------- | -------- | ------------------- |
| `bk_name` | string | 市场和板块,板块名称 |
| `rdate` | datetime | 报告期,报告期 |
| `top_n` | any | 用户自定义,取前N名 |
| `unit_type` | any | 用户自定义,显示单位 |
返回:bool