Skip to content

How to generate whole yield curve term structure tenors results use Hull White model? #13

Description

@jojogh

I search all document in the repository, and I found out that the if I use fitted curve, like below:

tenor_rates = [('3M', 0.0151, 0.01),
('6M', 0.0152, 0.01),
('9M', 0.0153, 0.01),
('1Y', 0.0154, 0.01),
('2Y', 0.0155, 0.01),
('3Y', 0.0156, 0.01),
('4Y', 0.0157, 0.01),
('5Y', 0.0158, 0.01),
('7Y', 0.0159, 0.01),
('10Y', 0.0160, 0.01),
('15Y', 0.0161, 0.01),
('20Y', 0.0162, 0.01)]

models = [hw1f]
corrMatrix = mx.IdentityMatrix(len(models))

timegrid1 = mx.TimeDateGrid_Equal(refDate=ref_date, maxYear=3, nPerYear=1)

results2 = xen.generate(models=models, calcs=None, corr=corrMatrix, timegrid=timegrid1,
rsg=sobol_rsg, filename=filename2, isMomentMatching=False)

ndarray = results2.toNumpyArr()

I found out that ndarray output only contained the very first tenor(3M tenor), may I ask how I can get the whole term tenors generated rates, like 9M, 1Y, 2Y, 3Y,....

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions