Skip to content

Commit

Permalink
Fix for non-LME curves in delta
Browse files Browse the repository at this point in the history
  • Loading branch information
gavbrennan committed Sep 10, 2024
1 parent 371031f commit f1be04d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/Qwack.Models/Risk/BasicMetrics.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
using Qwack.Core.Instruments.Asset;
using Qwack.Core.Models;
using Qwack.Dates;
using Qwack.Futures;
using Qwack.Math;
using Qwack.Models.MCModels;
using Qwack.Models.Models;
Expand Down Expand Up @@ -789,7 +790,7 @@ public static ICube AssetDelta(this IPvModel pvModel, bool computeGamma = false,

Dictionary<string, IPriceCurve> bumpedCurves;
Dictionary<string, IPriceCurve> bumpedDownCurves;
if (isSparseLMEMode)
if (isSparseLMEMode && curveObj is BasicPriceCurve bpc && bpc.CurveType == Transport.BasicTypes.PriceCurveType.LME)
{
lastDateInBook = NextThirdWeds(lastDateInBook);
var sparseDates = curveObj.PillarDates.Where(x => x <= lastDateInBook && DateExtensions.IsSparseLMEDate(x, curveObj.BuildDate, calendars)).ToArray();
Expand Down
2 changes: 1 addition & 1 deletion version.props
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Project>
<PropertyGroup>
<VersionPrefix>0.8.86</VersionPrefix>
<VersionPrefix>0.8.87</VersionPrefix>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.8.86
0.8.87

0 comments on commit f1be04d

Please sign in to comment.