using BaseOUDAL;
namespace YLErp.Model
{
public class RiskExposureModel
{
///
/// 品种
///
public string VarietyCode { get; set; }
///
/// 品种指数收盘价
///
public double? VarietyIndexClosePrice { get; set; }
///
/// 品种指数日波动率
///
public double? VarietyIndexDailyVol { get; set; }
public RiskIndicatorParameter FuturesIndicator { get; set; }
public OptionRiskIndicatorParameter OptionIndicator { get; set; }
public RiskIndicatorParameter PortfolioIndicator => new RiskIndicatorParameter
{
Delta = FuturesIndicator.Delta + OptionIndicator.Delta,
Pnl = FuturesIndicator.Pnl + OptionIndicator.Pnl
};
///
/// 组合Delta敞口比例
///
public double? DeltaExposureRatio { get; set; }
///
/// Gamma*日波动率*指数收盘价
///
public double? GammaDailyVolClosePrice { get; set; }
///
/// 风险价值
///
public double? VAR { get; set; }
///
/// 是否超敞口
///
public bool? IsOverexposure { get; set; }
}
public class RiskExposureModelSum
{
public double? FuturesPnlSum { get; set; }
public double? FuturesDeltaSum { get; set; }
public double? OptionPnlSum { get; set; }
public double? OptionDeltaSum { get; set; }
public double? OptionGamma { get; set; }
public double? PortfolioPnlSum { get; set; }
public double? PortfolioDeltaSum { get; set; }
public double? VARSum { get; set; }
}
public class RiskIndicatorParameter
{
///
/// 盈亏
///
public double? Pnl { get; set; }
public double? Delta { get; set; }
}
public class OptionRiskIndicatorParameter : RiskIndicatorParameter
{
public double? Gamma { get; set; }
}
public class RiskExposureReq : BaseSearchReq
{
///
/// 品种
///
public string VarietyCodes { get; set; }
///
/// 品种
///
public List VarietyCodeList => DataConvert.SplitByComma(VarietyCodes).ToList();
///
/// 结算日
///
public DateTime? SettlementDate { get; set; }
}
}