Class GlobalPiecewiseCubicZero
- Namespace
- NanoQL.TermStructures
- Assembly
- NanoQL.dll
A piecewise cubic zero-rate curve bootstrapped globally:
QuantLib-Python's GlobalPiecewiseCubicZero,
the PiecewiseYieldCurve<TTraits, TInterpolator, TBootstrap> on ZeroYield,
Cubic and GlobalBootstrap.
public sealed class GlobalPiecewiseCubicZero : PiecewiseYieldCurve<ZeroYield, Cubic, GlobalBootstrap>, IInterpolatedCurve<ZeroYield, Cubic>
- Inheritance
-
GlobalPiecewiseCubicZero
- Implements
- Inherited Members
- Extension Methods
Remarks
A convenience: nanoql's own code uses the generic class.
Constructors
GlobalPiecewiseCubicZero(Date, IEnumerable<BootstrapHelper<YieldTermStructure>>, DayCounter, EvaluationContext, IEnumerable<double>?, IEnumerable<Date>?, Cubic, GlobalBootstrap)
Initializes a new instance of the GlobalPiecewiseCubicZero class with a fixed reference date, and bootstraps it.
public GlobalPiecewiseCubicZero(Date referenceDate, IEnumerable<BootstrapHelper<YieldTermStructure>> instruments, DayCounter dayCounter, EvaluationContext context, IEnumerable<double>? jumps = null, IEnumerable<Date>? jumpDates = null, Cubic i = default, GlobalBootstrap bootstrap = default)
Parameters
referenceDateDateThe reference date.
instrumentsIEnumerable<BootstrapHelper<YieldTermStructure>>The helpers the curve is bootstrapped on.
dayCounterDayCounterThe day counter.
contextEvaluationContextThe evaluation context the helpers are dated and priced in.
jumpsIEnumerable<double>The discount-factor jumps, or null for none.
jumpDatesIEnumerable<Date>The jumps' dates, or null for 31 December of successive years.
iCubicThe interpolator.
bootstrapGlobalBootstrapThe bootstrap.
Exceptions
- ArgumentNullException
context,instrumentsordayCounteris null.- ArgumentException
A helper is null, the reference date is
default(Date), or the jumps and their dates differ in number.- NanoQLException
The bootstrap fails.
Methods
Create(int, Calendar, IEnumerable<BootstrapHelper<YieldTermStructure>>, DayCounter, EvaluationContext, IEnumerable<double>?, IEnumerable<Date>?, Cubic, GlobalBootstrap)
A curve with a reference date that is the evaluation date advanced by settlement days on a calendar: QuantLib's constructors taking settlement days, whose reference date moves with the evaluation date. The curve is built for the context's evaluation date.
public static GlobalPiecewiseCubicZero Create(int settlementDays, Calendar calendar, IEnumerable<BootstrapHelper<YieldTermStructure>> instruments, DayCounter dayCounter, EvaluationContext context, IEnumerable<double>? jumps = null, IEnumerable<Date>? jumpDates = null, Cubic i = default, GlobalBootstrap bootstrap = default)
Parameters
settlementDaysintThe settlement days.
calendarCalendarThe calendar the settlement days are counted on.
instrumentsIEnumerable<BootstrapHelper<YieldTermStructure>>The helpers the curve is bootstrapped on.
dayCounterDayCounterThe day counter.
contextEvaluationContextThe evaluation context.
jumpsIEnumerable<double>The discount-factor jumps, or null for none.
jumpDatesIEnumerable<Date>The jumps' dates, or null for 31 December of successive years.
iCubicThe interpolator.
bootstrapGlobalBootstrapThe bootstrap.
Returns
- GlobalPiecewiseCubicZero
The bootstrapped curve.
Exceptions
- ArgumentNullException
context,calendar,instrumentsordayCounteris null.- ArgumentOutOfRangeException
settlementDaysis negative.- ArgumentException
A helper is null, or the jumps and their dates differ in number.
- NanoQLException
The bootstrap fails.