pf_VARByHistoricalSimulation
简述
VAR-历史模拟法。
pf_VARByHistoricalSimulation(w:array;BegT:TdateTIME;EndT:TdateTIME;ConfidenceInterval:integer;MarketValue:real;DeltaT:integer;MethodType:Integer)
名称 | 类型 | 说明 |
---|
w | array | 数据表类型,组合信息 |
BegT | TdateTIME | 日期,开始日期 |
EndT | TdateTIME | 日期,截止日期 |
ConfidenceInterval | integer | 整数,置信度(%) |
MarketValue | real | 实数,组合市值 |
DeltaT | integer | 整数,未来持有期 |
MethodType | Integer | 用户自定义,组合最大亏损计算方法
显示名 |
取值 |
分位数法 |
0 |
分位数子序列均值法 |
1 |
|
返回 | | 实数 |
GetBkWeightByDate('SH000300', 20111231T,t);
s:=select ['指数代码'] as '行业代码',['代码'] ,['比例(%)'] from t end;
return pf_VARByHistoricalSimulation(s,20110101T,20111231T,95,10000,1,0);
返回:
238.41