I am using the pre-compiled Python version of Quantlib from the following website (QuantLib_Python-1.6.1-cp27-
none-win_amd64.whl )
http://www.lfd.uci.edu/~
gohlke/pythonlibs/#quantlib
When the code below is run it returns the following error:
TypeError: in method 'new_CallableFixedRateBond', argument 9 of type 'CallabilitySchedule const &':
schedule = Schedule(Date(25,
January,2010), Date(1,February,2020), Period(Semiannual), TARGET(),
ModifiedFollowing, DateGeneratModifiedFollowing, ion .Backward, False)
call_dates = [ ql.Date(25,
January,2016) ] call_price = 100.0
callability_schedule = ql.Call
abilitySchedule ()
for call_date in call_dates:
callability_price = ql.Cal
labilityPrice (call_price, ql.CallabilityPrice .Clean)callability_schedule.
append( ql.Callability(callability_price, ql.Callability .Call, call_date))
bond = ql.CallableFixedRateBon
d (3, 100.0, schedule, [0.0565], ql.Thirty360(), ql.ModifiedFollowing, 100.0, ql.Date (25,January,2010),callability_schedule)
Does anyone know why this error is being raised?
This message and any attachment are confidential and may be privileged or otherwise protected from disclosure. If you are not the intended recipient, please telephone or email the sender and delete this message and any attachment from your system. If you are not the intended recipient you must not copy this message or attachment or disclose the contents to any other person.
------------------------------------------------------------ ------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Free forum by Nabble | Disable Popup Ads | Edit this page |