Bootstrapping using Quantlib Python
PiecewiseYieldCurve is a class template, so it can't be exported to Python as such. By default, we're exporting to Python a particular instantiation of it; it's exported as PiecewiseFlatForward and it correspond to PiecewiseYieldCurve<ForwardRate,BackwardFlat>.
If you need another instantiation, you can edit QuantLib-SWIG/SWIG/piecewiseyieldcurve.i, add it (it you look at the end of the file, you'll find a few examples of how to do it) and regenerate and recompile the Python wrappers.
Finally, an example of bootstrap is available in QuantLib-SWIG/Python/examples/swap.py.
I want to bootstrap a yield curve in Python using QuantLib library.
I know that when doing bootstrapping using C++, there is a function for bootstrapping called PiecewiseYieldCurve in QuantLiab, but when I am using Python, there is no such function in Python QuantLib.
I wonder that if in Python QuantLib there is an alias of PiecewiseYieldCurve, so I have to call the alias function name in order to use PiecewiseYieldCurve function
Should I creating my own function to bootstrap the yield curve?
Thanks!