Quantlib is an open-source C++ library for quantitative finance.

learn more… | top users | synonyms

1
vote
0answers
49 views

QuantLib FittedBondDiscountCurve fitResults [Error]

I try to use FittedBondDiscountCurve with NelsonSiegelFitting, but I faced with error when call fitResults() method: ...
0
votes
1answer
33 views

Constructing yield curve directly from yield-to-maturity data

I'm trying to use Bloomberg yield-to-maturity data for sets of sovereign bonds of different maturities to fit to a yield curve. I looked into using the QuantLib library (the FittedBondCurve ...
1
vote
1answer
48 views

Calculating the greeks for Quantlib Python Swaptions

So I have created a Swaption object and can get the premium with the NPV() function. However, I would also like to calculate the greeks (eg. delta, vega). From some searching, I found that vega can ...
6
votes
4answers
187 views

How do you check your option calculations?

I'm implementing a bunch of different algorithms to price options/find Greeks: finite difference, Monte Carlo, binomial... I'm not really sure how to check my calculations. I tried using QuantLib to ...
1
vote
2answers
107 views

How to build a cross currency swap pricer?

We're looking to build a pricer to convert a funding spread in a given currency over a specific funding basis e.g. 20 bps EUR 3m€ and convert it to a funding spread to a different currency with a ...
1
vote
0answers
41 views

FIX engines comparison

Need help, looking for some comparison between c++ FIX engines, like onixs, antenna and some fpga solutions. If anyone has experienced some of the named engines also would like to hear the ...
0
votes
1answer
37 views

Open source code based on quandl for security analysis and options priming

Quandl seems to be an excellent source of wide range of free/open financial data. But is there an open source code or platform that uses the quandl datasets to perform security analysis and option ...
0
votes
0answers
29 views

Quantlib xll - Converting deposit/swap curve to zero curve

I am trying to create a spreadsheet using the Quantlib xll to convert deposit/swap rates to zero rates. I tried to implement such by referencing to the C++ code listed here: How to sum interest rate ...
1
vote
1answer
166 views

How to calculate bond yield in QuantLib - Python

I want to calculate yield of bond having market price and coupons. I try to replicate C++ from (https://mhittesdorf.wordpress.com/2013/03/03/introducing-quantlib-internal-rate-of-return/) in Python ...
2
votes
1answer
79 views

How many ways can QuantLib handle the price of option on its maturity date?

I have been playing with QuantLib for some time. This is a great framework with amazing design and capabilities. However, one thing that I find hard to understand is the way it handles the price of ...
0
votes
0answers
136 views

QuantLib importing in Python

Since I am working with a thesis, QuantLib is a very new thing for me. I have installed and compiled QuantLib, including the QuantLib-SWIG. Everything was compiled and installed using the guidlines at ...
0
votes
2answers
108 views

Compiling QuantLib example

I have followed the guidlines for installing QuantLib for mac from here http://quantlib.org/install/macosx.shtml and also fixed the flags using the commands: export CXXFLAGS = -stdlib=libstdc++ ...
1
vote
0answers
42 views

Quantlib binomial tree

I was trying to price options with the extendedBinomialTree class of quantlib. I actually tried at some point to modify this class in order to optimize it. Normally the drift and diffusion of the ...
0
votes
3answers
406 views

Quantlib with python on mac?

Is there anyone who knows a good guide to get quantlib working for python om mac? I have tried to search online and have not found any good guidance. I need to use quantlib for a project on python. ...
5
votes
4answers
159 views

How to select the initial guess for implied volatility?

When we calculate the implied volatility, we would need to give the solver a range to start with. For example, QuantLib uses [0,4.0] for the range, which is another way of saying try all possible ...
0
votes
1answer
80 views

Why QuantLib assumes zero rates to discount factor is continuous?

https://github.com/lballabio/QuantLib/blob/0ec43027834220baf0a554d68de79a159a2c5489/ql/termstructures/yield/zeroyieldstructure.hpp ...
0
votes
0answers
55 views

Need to know What is not available in RQuantlib

If we explore CRAN RQuantlib package it says The 'RQuantLib' package makes parts of 'QuantLib' accessible from R. When I tried the package I have found vanilla/some exotic options, fixed income ...
1
vote
1answer
68 views

AmericanOptionImpliedVolatility strange answers for calls IV's

My data provider includes the greeks. I tried to compute the IV's myself using RQuantLib and see if they match -- for Puts it's generally close, for Calls however certain values are way way off -- any ...
0
votes
1answer
244 views

AmericanOptionImpliedVolatility - root not bracketed issue in QuantLib/R

I'm trying to compute an implied volatility -- I am trying to match real data I see in Yahoo finance which shows an IV of about 27%. My call in 'R' for the same params returns a root not bracketed ...
2
votes
1answer
60 views

Debugging Quantlib

I am trying to understand Quantlib's finite-difference pricer using Eclipse with GDB debugger. The code shown below prices an American put option using the Crank-Nicholson finite-difference scheme. ...
1
vote
1answer
94 views

QuantLib: New Instrument derived from VanillaOption + PricingEngine that must work for both VanillaOption and the derived class

The derived class is a Vanilla Option on a Future and I need to specify the expiry of the underlying future which is in general different (later) than the expiry of the Vanilla Option. I have ...
1
vote
1answer
112 views

How to price touch options using quantlib?

I am new to quantlib and I want use it to to price a touch option (single/double). I searched on google for example code but I could not find anything. Hence, I am ...
3
votes
1answer
118 views

QuantLib C++: Monte Carlo Engine with SequenceStatistics

I'm trying to implement a Monte Carlo PricingEngine that stores multidimensional statistics. I have done the following: Defined a Monte Carlo Trait that among other things stores as the ...
3
votes
1answer
112 views

QuantLib: Is the StochasticProcess class adapt for a HJM type of modelling?

I would like to use the following model in QuantLib: $\frac{dF(t,T)}{F(t,T)} = \sigma_se^{-\beta(T-t)}dW_{t}^{1} + \sigma_L\left(1-e^{-\beta(T-t)}\right)dW_{t}^{2}$ This is a reformulation of the ...
7
votes
4answers
740 views

Why does it take so many lines of code to price even the simplest of options with QuantLib

I have been looking at QuantLib I am trying to figure out why I need to write so much boilerplate code even when pricing the "simplest" of European Options using the analytical Black-Scholes formula (...
2
votes
1answer
118 views

quantlib python : missing methods?

I'm reading Introduction to Selected Classes of the QuantLib Library I by Dimitri Reiswich and tries to "convert" it to Python. It seems to me that some C++ possibilities aren't available in python. I'...
1
vote
0answers
46 views

RQuantLib FixedRateBondPriceByYield() Non-tradable error

How do I use FixedRateBondPriceByYield() function on maturity date that is earlier than today? I get "non tradable error" when applying on date older than today. <...
0
votes
1answer
164 views

Quantlib bootstraping fails on 5y swap

I'm trying to build a euro swap curve with real up to date data. I should say that examples provided in github work fine. as soon as I add the 5y swap, I got the following error : ...
0
votes
1answer
75 views

Binary Option valuation problem in R using RQuantLib; also result validation aspect

When I am trying to value Binary Option using RQuantLib I am not getting all the greeks for exctype "american" wheras "european" exctype is fine. What is the problem here ? ...
3
votes
1answer
128 views

Quantlib FuturesRateHelper triggers not a valid IMM date error

I'm beginning to use QuantLib with Python SWIG, and trying to build a EUR yield curve. I face this error which frankly I don't understand; I looked at the code of bool IMM::isIMMdate in imm.cpp and ...
1
vote
0answers
77 views

QuantLib C++: Friendship dilemma between derived class from PiecewiseYieldCurve and Bootstrap class

I derived a class template, OISCurve<Traits,Interpolator,Bootstrap>, from ...
2
votes
1answer
94 views

CallableFloatingRateBond in QuantLib: just a matter of multiple inheritance?

I would like to know what are the issues related to a possible CallableFloatingRateBond class in QuantLib and to have some hints on implementation. My (very ...
1
vote
2answers
285 views

Why QuantLib computes the fixed-leg swap rate by this formula?

I'm trying to understand how QuantLib creates (bootstraps) a yield curve from a vanilla swap at the source level. I have the following test code: ...
1
vote
3answers
755 views

How to learn QuantLib-python at first?

In my project, I have to get the delta of up and out call option (with vol surface). I found out that QuantLib might help me on that. Since my main language is python and I don't know well about C++, ...
1
vote
1answer
93 views

Quantlib FRA with shifted start date

I'm new to quantlib. I am trying to construct a PiecewiseYieldCurve. I been looking at the implementation of FRA. It seems that the start date of the FRA must be an integer number of month from the ...
1
vote
1answer
346 views

How to use quantlib with excel?

I installed an quantlib on my mac, but have no idea, how to start using it with an excel. Please advise hoq to do it. I followed all instructions here: http://quantlib.org/install/macosx.shtml. I ...
3
votes
1answer
61 views

Why risk-free interest is needed for Margrabe's Formula?

The source code for Margarble's formula in QuantLib is here. The implementation requires a forward price be computed: ...
1
vote
1answer
226 views

Best way to do multithread Monte-Carlo in QuantLib

QuantLib has great facilities for Monte-Carlo pricing engines, classes McSimulation and MonteCarloModel do a lot of work. But they do it in a single thread. What is best way to introduce parallel run ...
2
votes
1answer
241 views

Black model: Delta - strike relationship regardless of expiry?

While wandering through some QuantLib experimental classes for FX trading, I've found this Black Delta Calculator. By reading its .cpp, it seems that no use of ...
0
votes
2answers
1k views

Bootstrap yield curve with QLNet / Quantlib

I am trying to grasp QLNet (C# version of Quantlib, all the functions of Quantlib have the same name and work the same way, so if you just know Quantlib, you can still help me), especially for pricing ...
3
votes
0answers
55 views

How do I specify Thirty360::European day counter in RQuantLib

I am taking liberty to ask the following question in quantLib forum though this question is about RQuantLib I am trying to use RQuantLib to calculate clean price of a fixed coupon bond using a Nelson-...
4
votes
1answer
91 views

BlackProcess' constructor $x_{0}$ argument in QuantLib

I am currently using BlackProcess to price options and I have a doubt related to the $x_{0}$ argument of the constructor: I've figured out it should be the forward ...
5
votes
1answer
812 views

QuantLib: Black / BSM processes and pricing via volatility surface. Different results?

I start this question with a couple of C++ functions that will be useful to show some results. So start your Visual Studio C++ Express or Ceemple or whatever you want and copy & paste this: ...
3
votes
1answer
2k views

Pricing a FixedRateBond in Quantlib: yield vs TermStructure

I am trying to price a simple U.S. treasury in QuantLib, using two methods. The first method calls FixedRatebond.dirtyPrice(...), passing in a YTM and other parameters. The second method involves ...
1
vote
1answer
226 views

novice question on fixed coupon schedule in QuantLib

For some bonds I work with the last coupon date is not equal to bond's maturity date. E.g. the last coupon date is April 25th, 2020 and maturity date is April 25th, 2021. I looked at Schedule class ...
2
votes
1answer
199 views

QuantLibXL - Optionlet bootstrapping failure

I am trying to bootstrap the Optionlet volatility surface from a Cap/Floor volatility surface using QuantLibXL. To be specific, the data is from ICAP: ...
6
votes
1answer
202 views

Pricing a bond with variable strike collar with QuantLibXL

I am trying to price a floating rate bond with a capped and floored interest rate. The strikes of the caps and floors vary, but are known in advance. I am trying to do this with QuantLibXL, but I am ...
3
votes
1answer
608 views

How to manage evaluation date changes in QuantLib while using ImpliedTermStructure Class

I will not attach the whole code 'cause it would be just a huge waste of space and it would be not useful for this question's purpose. What I am going to attach here is a snippet code and its output, ...
3
votes
1answer
986 views

How to sum interest rate curves in QuantLib

C++ code taken from Bonds.cpp and slightly amended: ...
4
votes
2answers
2k views

What is the best alternative of Quantlib library

We need to build a Fixed Income Portfolio Risk Analytics solution. Somehow due to administrative reason we can't use Quantlib which is written in C++, even call it through SWIG via JNI. We have tried ...