Comments (4)
Hi @avhz and @MeetThePatel,
Thank you both for your valuable inputs. I appreciate the direction regarding the placement of the implied volatility function. Following your suggestions, I will proceed with implementing the feature in ./src/instruments/options/implied_volatility.rs
and ensure that the naming is clear and descriptive.
Regarding the choice of algorithm, I agree with @avhz that a user-friendly and fast solution is crucial. I'm confident in working with Peter Jäckel's method as it's well-established and known for its efficiency. I'll focus on implementing this method first, ensuring it integrates smoothly into our codebase with an emphasis on speed and ease of use.
@MeetThePatel, your suggestion to compare Jäckel's method with the Li & Lee method is intriguing. It could provide us with valuable insights into the performance trade-offs between these two approaches. If you're willing to implement the Li & Lee method, we could run a comparative analysis to evaluate their respective performances. This could be a great way to ensure we're providing the most efficient solution in our codebase.
I'll start working on the Jäckel implementation and keep you both updated on my progress. Looking forward to seeing how the Li & Lee implementation shapes up as well, if you decide to go ahead with it.
from rustquant.
Would it make sense to put it in src/instruments/options
? greeks.rs
is in that directory, so would it make sense to put implied volatility computation in src/instruments/options/implied_volatility.rs
or src/instruments/options/iv.rs
?
Also, with regards to the actual IV calculation: do you know if that method is faster than successive over-relation (https://papers.ssrn.com/sol3/papers.cfm?abstract_id=1027282). Just from a cursory reading, it seems that the order of convergence of Halley's method is cubic and the order of convergence of successive over-relation is quadratic (after some transformations); however, I'm not sure as to how that translates into actual runtime.
from rustquant.
Hi @lukaskiss222 thanks for your interest! Sorry for my delayed response, I'm very busy at the moment.
Having an IV implementation is needed for sure, so I'd definitely welcome your contribution.
The appropriate place would be ./src/instruments/options/implied_volatility.rs
as @MeetThePatel suggested. I would prefer more descriptive names (e.g. implied_volatility
over iv
).
I am not particularly fussed over the specific algorithm, my preference would just be a user-friendly API. In saying that, for something like IV, I would say faster is better. I'm not familiar with the Li & Lee paper though, and I don't have the time at the moment to read it in detail unfortunately. So it may be that their algorithm is faster.
But Jaeckel's is very well established and fast as far as I am aware, and if you (@lukaskiss222) are familiar with it, by all means go with his.
from rustquant.
Related Issues (20)
- Fix code scanning alert - useless use of vec!
- Error handling - `data` module.
- Error handling - `instruments` module.
- Error handling - `math` module.
- Error handling - `ml` module. HOT 2
- Error handling - `money` module.
- Error handling - `statistics` module. HOT 1
- Error handling - `stochastics` module.
- Error handling - `time` module.
- Implement `num_traits::identities::{One, Zero}` for `Variable`
- Include all features on docs.rs. HOT 4
- Unify `ml` input data type to one interface HOT 3
- Implement a `Surface` type. HOT 7
- Add more calendars. HOT 7
- Implement Interest Rate Swap pricer. HOT 2
- feat(stochastics): Have time-varying parameters for processes HOT 5
- Use Release-Plz for automatic releases. HOT 6
- Add CEV process
- feat: Portfolio to have a get_weights() function or something similar HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rustquant.