Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance FX Single Barrier Option pricers #2349

Merged
merged 2 commits into from
Aug 27, 2021

Conversation

skitini
Copy link
Contributor

@skitini skitini commented Aug 26, 2021

  • Add implied volatility and forward FX rate calculations to FX single barrier options trade and product pricers
  • Add forward FX rate calculation to FX vanilla option product pricer
  • Tidy FX vanilla option trade pricer test

Copy link
Contributor

@ChristianOG ChristianOG left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If there's a simple Stephen-approved way to implement my recommendations, then please do so. Otherwise, I hereby approve as-is.

@@ -362,6 +366,47 @@ public double theta(
return -priceDerivatives.getDerivative(5);
}

//-------------------------------------------------------------------------
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

arguably these two (forward rate and vol) are fairly generic helper functions which could be used for pretty much any fx product (with vol for the vol query). can we find these two a better home, maybe in an fxutils package?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

akshually... it would be best to add an abstract function like paymentDate() to FxProduct and then add the forwardFxRate() function to the FxProduct interface. For the vol queries do something similar with the FxOptionProduct interface.

@skitini skitini added the auto-merge Merge when build finishes label Aug 27, 2021
@mergify mergify bot merged commit 1d4316d into main Aug 27, 2021
@delete-merged-branch delete-merged-branch bot deleted the topic/vol-forward-calcs-fx-barrier-option branch August 27, 2021 14:18
@jodastephen jodastephen added Type:Enhancement and removed auto-merge Merge when build finishes labels Sep 3, 2021
@jodastephen jodastephen added this to the v2.11 milestone Jan 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants