-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move transformation used in GlobalBootstrap into Traits
Also, use exp instead of atan transformation for discount factors. This is an improvement on #2120 based on these observations: * Rates-based traits don't need any constraints in the optimization, so we don't need any transformation with them. This removes unnecessary computations. * Discount factors are only bounded on one side (have to be positive), so instead of estimating a max value to use atan, we can simply use exp. This is faster and uses fewer magic numbers. Another issue with atan is that it changes the gradients too much when the value is far from the middle of the range. This pushes optimization away from the correct solution when rates are low. This makes it hard to find value of maxDF that works for both very low and very high rates.
- Loading branch information
Showing
2 changed files
with
26 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters