8.7 KiB
基金研究 / 行业配置
TS_IndustryAllocationOfFund
声明:class
基金季报行业配置估计框架
fFundsArr
声明:field
基金序列 股混型基金
可见性:public
类型:array
frDate
声明:field
报告期
可见性:public
类型:integer
fhyType
声明:field
新行业分类标准 1:申万一级行业分类
可见性:public
类型:integer
getFundAAStockMValue(fund_id, v_r_date)
声明:function
获取指定报告期基金股票市值数据
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:real
getIndustryData(fund_id, v_r_date)
声明:function
获取指定报告期内基金行业配置情况
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
getStockData(fund_id, v_r_date)
声明:function
获取指定报告期内基金持股情况
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
top10Stocks(fund_id, v_r_date)
声明:function
获取指定报告期内基金重仓股情况
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
belongToIndustry(fund_id, v_r_date)
声明:function
获取指定报告期内基金重仓股的行业分布情况
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
notInTop10IndustryData(fund_id, v_r_date)
声明:function
获取指定报告期内基金非重仓股的行业分布情况
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
getAbkStocks(v_r_date)
声明:function
获取指定报告期内全市场股票池
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
getfunds()
声明:function
获取报告期内符合筛选条件的基金代码序列
可见性:public
返回:array
getStockNewIndustry(stocks, v_r_date, hy_type)
声明:function
股票对应的新行业分类,通过参数 HYType 可选择申万或中证一级行业分类,若有其他行业
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
stocks |
array | 待分类或计算的股票数据表 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
hy_type |
integer | 行业分类标准选择项 |
getNewIndustry(stocks, fund_id, v_r_date)
声明:function
根据股票所属新行业计算新行业分布
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
stocks |
array | 待分类或计算的股票数据表 |
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
industryWeight(stocks, fund_id, v_r_date)
声明:function
按照计算新行业配置比例时使用的股票数据来源进行分类
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
stocks |
array | 待分类或计算的股票数据表 |
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
stocksSimulation(fund_id, v_r_date)
声明:function
根据重仓股补全法对基金指定报告期持仓进行模拟
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
stocksHoldings(fund_id, v_r_date)
声明:function
基金全部持仓,一三季报为重仓股补全模拟后的全部持仓,中报年报为基金实际持仓
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
v_r_date |
datetime | 基金报告期,用于确定持仓或行业数据快照 |
返回:array
allocation()
声明:function
Allocation 为基金季报行业配置估计框架的总接口
可见性:public
industrySimulation()
声明:function
以基金最终全部持仓为准计算基金行业分布,默认申万一级行业分类
可见性:public
返回:array
industryDetails()
声明:function
以基金最终全部持仓为准根据数据来源不同计算各部分的行业配置结果
可见性:public
返回:array
stockDetails(fund_id)
声明:function
返回指定基金全部持仓明细,若不指定基金则返回所有测算基金全部结果
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
fund_id |
string | 基金代码 |
返回:array
fund_GetIndustryAllocation(end_t, type)
声明:function
获取基金季报行业配置估计,与证券代码相关
可见性:public
| 参数 | 类型 | 说明 |
|---|---|---|
end_t |
datetime | 日期类型,截止日 Type_:整数类型,行业类别 Type_取值 含义 1 申万行业 2 中证行业 90 公布的证监会行业 91 取衍生的申万行业 |
type |
int | 评价层次或返回类型选择项 |
返回:array