天软金融分析.NET函数大全 > 金融函数 > 金融工程 > 策略验证 > 数量类中间函数 > 中间函数

GetPriceOfUnderlying    

简述
指定日期权标的证券价格
定义
GetPriceOfUnderlying(OptionID:String;EndT:TDateTime;isOpen:Integer):Real
参数
名称类型说明
OptionIDString字符串,期权代码
EndTTDateTime日期型时间,截止日
isOpenInteger是否获取期权标的证券昨价格
返回Real期权标的证券价格
  • 范例

    范例一:
    //期权标的证券系统昨收
    OptionID:='OP10004679';
    EndT:=inttodate(20230104);
    isOpen:=1;
    return GetPriceOfUnderlying(OptionID,EndT,isOpen);
    //结果:2.651

    范例二:
    //期权标的证券收盘
    OptionID:='OP10004679';
    EndT:=inttodate(20230104);
    return GetPriceOfUnderlying(OptionID,EndT);
    //结果:2.66
相关