caveats

Langue: en

Autres versions - même langue

Version: 161487 (fedora - 05/07/09)

Section: 3 (Bibliothèques de fonctions)

Sommaire

NAME

caveats - Caveats
 
Class Actual365Fixed
According to ISDA, 'Actual/365' (without 'Fixed') is an alias for 'Actual/Actual (ISDA)' (see ActualActual.) If Actual/365 is not explicitly specified as fixed in an instrument specification, you might want to double-check its meaning.


 

Member QuantLib::BarrierOption::impliedVolatility(Real price, const boost::shared_ptr< GeneralizedBlackScholesProcess > &process, Real accuracy=1.0e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const
see VanillaOption for notes on implied-volatility calculation.


 

Member QuantLib::BespokeCalendar::BespokeCalendar(const std::string &name='')
different bespoke calendars created with the same name (or different bespoke calendars created with no name) will compare as equal.


 

Member QuantLib::BlackAtmVolCurve::BlackAtmVolCurve(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class BlackCallableFixedRateBondEngine
This class has yet to be tested


 

Class BlackCallableZeroCouponBondEngine
This class has yet to be tested.


 

Class BlackSwaptionEngine
The engine assumes that the exercise date equals the start date of the passed swap.


 

Member QuantLib::BlackVarianceTermStructure::BlackVarianceTermStructure(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::BlackVolatilityTermStructure::BlackVolatilityTermStructure(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::BlackVolSurface::BlackVolSurface(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::BlackVolTermStructure::BlackVolTermStructure(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class Bond
Most methods assume that the cash flows are stored sorted by date, the redemption(s) being after any cash flow at the same date. In particular, if there's one single redemption, it must be the last cash flow,


 

Member QuantLib::Bond::cleanPrice() const
the theoretical price calculated from a flat term structure might differ slightly from the price calculated from the corresponding yield by means of the other overload of this function. If the price from a constant yield is desired, it is advisable to use such other overload.


 

Member QuantLib::Bond::dirtyPrice() const
the theoretical price calculated from a flat term structure might differ slightly from the price calculated from the corresponding yield by means of the other overload of this function. If the price from a constant yield is desired, it is advisable to use such other overload.


 

Member QuantLib::Bond::Bond(Natural settlementDays, const Calendar &calendar, Real faceAmount, const Date &maturityDate, const Date &issueDate=Date(), const Leg &cashflows=Leg())
The last passed cash flow must be the bond redemption. No other cash flow can have a date later than the redemption date.


 

Member QuantLib::BootstrapHelper::setTermStructure(TS *)
Being a pointer and not a shared_ptr, the term structure is not guaranteed to remain allocated for the whole life of the rate helper. It is responsibility of the programmer to ensure that the pointer remains valid. It is advised that this method is called only inside the term structure being bootstrapped, setting the pointer to this, i.e., the term structure itself.


 

Class CADLibor
This is the rate fixed in London by BBA. Use CDOR if you're interested in the Canadian fixing by IDA.


 

Member QuantLib::Calendar::name() const
This method is used for output and comparison between calendars. It is not meant to be used for writing switch-on-type code.


 

Member QuantLib::CallableBondVolatilityStructure::CallableBondVolatilityStructure(const DayCounter &dc=DayCounter(), BusinessDayConvention bdc=Following)
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::CapFloorTermVolatilityStructure::CapFloorTermVolatilityStructure(const Calendar &cal, BusinessDayConvention bdc, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class Cdor
This is the rate fixed in Canada by IDA. Use CADLibor if you're interested in the London fixing by BBA.


 

Class CdsOption
the current implementation does not take premium accrual into account


 

Class CdsOption
the current implementation quietly assumes that the expiry equals the start date of the underlying CDS


 

Class CHFLibor
This is the rate fixed in London by BBA. Use ZIBOR if you're interested in the Zurich fixing.


 

Class CmsCoupon
This class does not perform any date adjustment, i.e., the start and end date passed upon construction should be already rolled to a business day.


 

Class CompositeInstrument
Methods that drive the calculation directly (such as recalculate(), freeze() and others) might not work correctly.


 

Class ConvertibleFixedCouponBond
Most methods inherited from Bond (such as yield or the yield-based dirtyPrice and cleanPrice) refer to the underlying plain-vanilla bond and do not take convertibility and callability into account.


 

Class ConvertibleFloatingRateBond
Most methods inherited from Bond (such as yield or the yield-based dirtyPrice and cleanPrice) refer to the underlying plain-vanilla bond and do not take convertibility and callability into account.


 

Class ConvertibleZeroCouponBond
Most methods inherited from Bond (such as yield or the yield-based dirtyPrice and cleanPrice) refer to the underlying plain-vanilla bond and do not take convertibility and callability into account.


 

Member QuantLib::Coupon::Coupon(Real nominal, const Date &paymentDate, const Date &accrualStartDate, const Date &accrualEndDate, const Date &refPeriodStart=Date(), const Date &refPeriodEnd=Date())
the coupon does not adjust the payment date which must already be a business day.


 

Class CrankNicolson< Operator >
The differential operator must be linear for this evolver to work.


 

Class CreditDefaultSwap
if QL_TODAYS_PAYMENTS was defined (in userconfig.hpp or when calling ./configure; it is undefined by default) payments occurring at the settlement date of the swap are included in the NPV, and therefore affect the fair-spread calculation. This might not be what you want.


 

Class CubicBSplinesFitting


 

Class DailyTenorEuribor
This is the rate fixed by the ECB. Use EurLibor if you're interested in the London fixing by BBA.


 

Class DailyTenorEURLibor
This is the rate fixed in London by BBA. Use Euribor if you're interested in the fixing by the ECB.


 

Member QuantLib::DayCounter::name() const
This method is used for output and comparison between day counters. It is not meant to be used for writing switch-on-type code.


 

Member QuantLib::DefaultDensityStructure::DefaultDensityStructure(const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::DefaultProbabilityTermStructure::DefaultProbabilityTermStructure(const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class DiscretizedOption
it is advised that derived classes take care of creating and initializing themselves an instance of the underlying.


 

Class Disposable< T >
In order to avoid copies in code such as shown above, the conversion from T to Disposable<T> is destructive, i.e., it does not preserve the state of the original object. Therefore, it is necessary for the developer to avoid code such as


 

Member QuantLib::DividendVanillaOption::impliedVolatility(Real price, const boost::shared_ptr< GeneralizedBlackScholesProcess > &process, Real accuracy=1.0e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const
see VanillaOption for notes on implied-volatility calculation.


 

Member QuantLib::EquityFXVolSurface::EquityFXVolSurface(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class Euribor
This is the rate fixed by the ECB. Use EurLibor if you're interested in the London fixing by BBA.


 

Class EURLibor
This is the rate fixed in London by BBA. Use Euribor if you're interested in the fixing by the ECB.


 

Member QuantLib::ExchangeRateManager::lookup(const Currency &source, const Currency &target, Date date=Date(), ExchangeRate::Type type=ExchangeRateDerived) const
if two or more exchange-rate chains are possible which allow to specify a requested rate, it is unspecified which one is returned.


 

Class ExponentialSplinesFitting
convergence may be slow


 

Member QuantLib::FiniteDifferenceModel::rollback(array_type &a, Time from, Time to, Size steps)
being this a rollback, from must be a later time than to.


 

Member QuantLib::FiniteDifferenceModel::rollback(array_type &a, Time from, Time to, Size steps, const condition_type &condition)
being this a rollback, from must be a later time than to.


 

Class FittedBondDiscountCurve
The method can be slow if there are many bonds to fit. Speed also depends on the particular choice of fitting method chosen and its convergence properties under optimization. See also todo list for BondDiscountCurveFittingMethod.


 

Class FittedBondDiscountCurve::FittingMethod
some parameters to the Simplex optimization method may need to be tweaked internally to the class, depending on the fitting method used, in order to get proper/reasonable/faster convergence.


 

Class FixedRateBondForward
This class still needs to be rigorously tested


 

Class FixedRateBondHelper
This class assumes that the reference date does not change between calls of setTermStructure().


 

Member QuantLib::FixedRateBondHelper::FixedRateBondHelper(const Handle< Quote > &cleanPrice, const boost::shared_ptr< FixedRateBond > &bond)
Setting a pricing engine to the passed bond from external code will cause the bootstrap to fail or to give wrong results. It is advised to discard the bond after creating the helper, so that the helper has sole ownership of it.


 

Class Forward
This class still needs to be rigorously tested


 

Member QuantLib::ForwardRateStructure::zeroYieldImpl(Time) const
This is just a default, highly inefficient and possibly wildly inaccurate implementation. Derived classes should implement their own zeroYield method.


 

Class G2SwaptionEngine
The engine assumes that the exercise date equals the start date of the passed swap.


 

Class GapPayoff
this payoff can be negative depending on the strikes


 

Member QuantLib::Handle::Handle(const boost::shared_ptr< T > &h=boostshared_ptr< T >(), bool registerAsObserver=true)
registerAsObserver is left as a backdoor in case the programmer cannot guarantee that the object pointed to will remain alive for the whole lifetime of the handle---namely, it should be set to false when the passed shared pointer does not own the pointee (this should only happen in a controlled environment, so that the programmer is aware of it). Failure to do so can very likely result in a program crash. If the programmer does want the handle to register as observer of such a shared pointer, it is his responsibility to ensure that the handle gets destroyed before the pointed object does.


 

Member QuantLib::HazardRateStructure::HazardRateStructure(const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class HimalayaOption
This implementation still does not manage seasoned options.


 

Member QuantLib::IMM::code(const Date &immDate)
It raises an exception if the input date is not an IMM date


 

Member QuantLib::IMM::date(const std::string &immCode, const Date &referenceDate=Date())
It raises an exception if the input string is not an IMM code


 

Class ImpliedVolTermStructure
It doesn't make financial sense to have an asset-dependant implied Vol Term Structure. This class should be used with term structures that are time dependant only.


 

Class IncrementalStatistics
high moments are numerically unstable for high average/standardDeviation ratios.


 

Class Index
this class performs no check that the provided/requested fixings are for dates in the past, i.e. for dates less than or equal to the evaluation date. It is up to the client code to take care of possible inconsistencies due to 'seeing in the future'


 

Member QuantLib::Index::name() const =0
This method is used for output and comparison between indexes. It is not meant to be used for writing switch-on-type code.


 

Member QuantLib::Instrument::setPricingEngine(const boost::shared_ptr< PricingEngine > &)
calling this method will have no effects in case the performCalculation method was overridden in a derived class.


 

Member QuantLib::InterestRate::discountFactor(Time t) const
Time must be measured using InterestRate's own day counter.


 

Member QuantLib::InterestRate::compoundFactor(Time t) const
Time must be measured using InterestRate's own day counter.


 

Member QuantLib::InterestRate::equivalentRate(Time t, Compounding comp, Frequency freq=Annual) const
Time must be measured using the InterestRate's own day counter.


 

Member QuantLib::InterestRate::impliedRate(Real compound, Time t, const DayCounter &resultDC, Compounding comp, Frequency freq=Annual)
Time must be measured using the day-counter provided as input.


 

Member QuantLib::InterestRateVolSurface::InterestRateVolSurface(const boost::shared_ptr< InterestRateIndex > &, const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class JamshidianSwaptionEngine
The engine assumes that the exercise date equals the start date of the passed swap.


 

Class JPYLibor
This is the rate fixed in London by BBA. Use TIBOR if you're interested in the Tokio fixing.


 

Class JuQuadraticApproximationEngine
Barone-Adesi-Whaley critical commodity price calculation is used, it has not been modified to see whether the method of Ju is faster. Ju does not say how he solves the equation for the critical stock price, e.g. Newton method. He just gives the solution. The method of BAW gives answers to the same accuracy as in Ju (1999).


 

Member QuantLib::Lattice::partialRollback(DiscretizedAsset &, Time to) const =0
In version 0.3.7 and earlier, this method was called rollAlmostBack method and performed pre-adjustment. This is no longer true; when migrating your code, you'll have to replace calls such as:


 

Member QuantLib::LazyObject::calculate() const
Objects cache the results of the previous calculation. Such results will be returned upon later invocations of calculate. When the results depend on arguments which could change between invocations, the lazy object must register itself as observer of such objects for the calculations to be performed again when they change.


 

Member QuantLib::LazyObject::calculate() const
Should this method be redefined in derived classes, LazyObject::calculate() should be called in the overriding method.


 

Class LiborForwardModelProcess
this class does not work correctly with Visual C++ 6.


 

Member QuantLib::LocalVolTermStructure::LocalVolTermStructure(const Calendar &cal=Calendar(), BusinessDayConvention bdc=Following, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member pseudoSqrt
Higham algorithm only works for correlation matrices.


 

Class MCAmericanBasketEngine< RNG >
This method is intrinsically weak for out-of-the-money options.


 

Class MCDiscreteAveragingAsianEngine< RNG, S >
control-variate calculation is disabled under VC++6.


 

Class MixedScheme< Operator >
The differential operator must be linear for this evolver to work.


 

Class NeumannBC
The value passed must not be the value of the derivative. Instead, it must be comprehensive of the grid step between the first two points--i.e., it must be the difference between f[0] and f[1].


 

Member QuantLib::Observable::operator=(const Observable &)
notification is sent before the copy constructor has a chance of actually change the data members. Therefore, observers whose update() method tries to use their observables will not see the updated values. It is suggested that the update() method just raise a flag in order to trigger a later recalculation.


 

Member QuantLib::OptionletVolatilityStructure::OptionletVolatilityStructure(const Calendar &cal, BusinessDayConvention bdc, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class PagodaOption
This implementation still does not manage seasoned options.


 

Member QuantLib::PathPayoff::name() const =0
This method is used for output and comparison between payoffs. It is not meant to be used for writing switch-on-type code.


 

Member QuantLib::Payoff::name() const =0
This method is used for output and comparison between payoffs. It is not meant to be used for writing switch-on-type code.


 

Class PiecewiseDefaultCurve< Traits, Interpolator, Bootstrap >
The bootstrapping algorithm will raise an exception if any two instruments have the same maturity date.


 

Class PiecewiseYieldCurve< Traits, Interpolator, Bootstrap >
The bootstrapping algorithm will raise an exception if any two instruments have the same maturity date.


 

Member QuantLib::Problem::reset()
it does not reset the current minumum to any initial value


 

Class QuantoEngine< Instr, Engine >
for the time being, this engine will only work with simple Black-Scholes processes (i.e., no Merton.)


 

Class RandomizedLDS< LDS, PRS >
Inverting LDS and PRS is possible, but it doesn't make sense.


 

Class RandomSequenceGenerator< RNG >
do not use with low-discrepancy sequence generator.


 

Member QuantLib::RelinkableHandle::RelinkableHandle(const boost::shared_ptr< T > &h=boostshared_ptr< T >(), bool registerAsObserver=true)
see the Handle documentation for issues relatives to registerAsObserver.


 

Member QuantLib::RelinkableHandle::linkTo(const boost::shared_ptr< T > &, bool registerAsObserver=true)
see the Handle documentation for issues relatives to registerAsObserver.


 

Member QuantLib::Rounding::Type
the names of the Floor and Ceiling methods might be misleading. Check the provided reference.


 

Member QuantLib::Settings::evaluationDate()
a notification is not sent when the evaluation date changes for natural causes---i.e., a date was not explicitly set (which results in today's date being used for pricing) and the current date changes as the clock strikes midnight.


 

Class SimpleDayCounter
this day counter should be used together with NullCalendar, which ensures that dates at whole-month distances share the same day of month. It is not guaranteed to work with any other calendar.


 

Member QuantLib::SingleAssetOption::impliedVolatility(Real targetValue, Real accuracy=1e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const
Options with a gamma that changes sign have values that are not monotonic in the volatility, e.g binary options. In these cases impliedVolatility can fail and in any case is meaningless. Another possible source of failure is to have a targetValue that is not attainable with any volatility, e.g. a targetValue lower than the intrinsic value in the case of American options.


 

Member QuantLib::SwapIndex::underlyingSwap(const Date &fixingDate) const
Relinking the term structure underlying the index will not have effect on the returned swap.


 

Class SwaptionVolatilityCube
this class is not finalized and its interface might change in subsequent releases.


 

Member QuantLib::SwaptionVolatilityStructure::SwaptionVolatilityStructure(const Calendar &calendar, BusinessDayConvention bdc, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::TermStructure::TermStructure(const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Class Tibor
This is the rate fixed in Tokio by JBA. Use JPYLibor if you're interested in the London fixing by BBA.


 

Class TreeSwaptionEngine
This engine is not guaranteed to work if the underlying swap has a start date in the past, i.e., before today's date. When using this engine, prune the initial part of the swap so that it starts at $ t geq 0 $.


 

Class TridiagonalOperator
to use real time-dependant algebra, you must overload the corresponding operators in the inheriting time-dependent class.


 

Class TrinomialTree
The diffusion term of the SDE must be independent of the underlying process.


 

Member QuantLib::VanillaOption::impliedVolatility(Real price, const boost::shared_ptr< GeneralizedBlackScholesProcess > &process, Real accuracy=1.0e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const
currently, this method returns the Black-Scholes implied volatility using analytic formulas for European options and a finite-difference method for American and Bermudan options. It will give unconsistent results if the pricing was performed with any other methods (such as jump-diffusion models.)


 

Member QuantLib::VanillaOption::impliedVolatility(Real price, const boost::shared_ptr< GeneralizedBlackScholesProcess > &process, Real accuracy=1.0e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const
options with a gamma that changes sign (e.g., binary options) have values that are not monotonic in the volatility. In these cases, the calculation can fail and the result (if any) is almost meaningless. Another possible source of failure is to have a target value that is not attainable with any volatility, e.g., a target value lower than the intrinsic value in the case of American options.


 

Class VanillaSwap
if QL_TODAYS_PAYMENTS was defined (in userconfig.hpp or when calling ./configure; it is undefined by default) payments occurring at the settlement date of the swap are included in the NPV, and therefore affect the fair-rate and fair-spread calculation. This might not be what you want.


 

Class VarianceOption
This class does not manage seasoned variance options.


 

Class VarianceSwap
This class does not manage seasoned variance swaps.


 

Member QuantLib::VolatilityTermStructure::VolatilityTermStructure(const Calendar &cal, BusinessDayConvention bdc, const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::YieldTermStructure::YieldTermStructure(const DayCounter &dc=DayCounter())
term structures initialized by means of this constructor must manage their own reference date by overriding the referenceDate() method.


 

Member QuantLib::YieldTermStructure::forwardRate(const Date &d, const Period &p, const DayCounter &resultDayCounter, Compounding comp, Frequency freq=Annual, bool extrapolate=false) const
dates are not adjusted for holidays


 

Class Zibor
This is the rate fixed in Zurich by BBA. Use CHFLibor if you're interested in the London fixing by BBA.