-
Notifications
You must be signed in to change notification settings - Fork 29
Release/v0.2.5 #71
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
Merged
Merged
Release/v0.2.5 #71
Conversation
This file contains hidden or 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
Updated README, library docs, and Cargo.toml to reflect the new version 0.2.5. This update prepares the library for the next release, ensuring consistency across metadata and documentation.
Replaced relative image URLs with absolute links to ensure proper rendering on external platforms. Added new badges for issues, pull requests, and documentation to improve project visibility and accessibility. The updates enhance the overall presentation and usability of both the README and library documentation.
Updated the OptionChain struct and related methods to include optional fields for risk-free rate and dividend yield. Adjusted tests and iterators to reflect the new parameters. Added functionality to retrieve pricing parameters with default fallbacks for the new fields. (ref. #62)
Introduce `filter_combinations` method in the base strategy to outline potential logic for filtering and grouping option data. Currently, the method returns an empty iterator and logs an error, serving as a scaffold for future implementation. (ref. #62)
The `OptionChainParams` trait now includes a `strike_price` parameter in the `get_params` method for enhanced flexibility. Additionally, the `OptionDataGroup` enum was introduced to handle grouped option data efficiently. These changes improve functionality and code organization. (ref. #62)
This new method allows creating `ExpirationDate` instances from strings. It supports parsing both durations in days and RFC3339 datetime formats, with appropriate error handling for invalid input. (ref. #62)
Added new optional parameters to `OptionChain` initialization across strategies and modified their usage accordingly. Enhanced `BullPutSpread` with new traits and functionalities, including position handling, validation, and optimization logic. (ref. #62)
Refreshed multiple strategy-related profit/loss charts to improve clarity and accuracy. This update ensures consistency and better representation across visual assets for analytical purposes.
Refreshed the profit/loss visualizations for long and short strangle strategies to improve accuracy and presentation. Ensures the charts align with the latest calculations and strategy updates.
Updated visualizations to reflect the latest calculations for best area and best ratio scenarios. These changes provide clearer and more accurate insights for the respective strategies.
Refined the profit/loss chart images for better clarity and precision. This ensures more accurate visual representation of the best area and ratio in the iron butterfly strategy.
Refined the visuals for best area and best ratio charts to improve clarity and presentation. These updates ensure better readability and enhanced interpretation of the strategy metrics.
Introduce a new 'zip' target to package the project into a ZIP file, excluding 'target' directories, 'Cargo.lock', and hidden files. This simplifies project archiving and distribution while ensuring unnecessary files are excluded.
This new method provides an iterator to access the `options` field in the `OptionChain` structure. It simplifies traversal of the `OptionData` elements, leveraging `BTreeSet` ordering for consistent iteration.
Introduced the `One` variant to the `OptionDataGroup` enum to handle a single `OptionData` reference. This enhancement improves flexibility for cases with only one `OptionData` item.
This update modifies the chart configuration to disable the mesh grid. The change ensures a cleaner visualization by removing the grid lines while retaining x and y axis labels.
Replaced nested loops with a reusable `filter_combinations` method for both Iron Condor and Iron Butterfly strategies. This improves code readability, reduces redundancy, and ensures better validation of strategy constraints. Minor logging adjustments and dead code removal were also made. (ref. #62)
Introduced a shared filtering method across spread strategies to standardize and simplify combination selection. Ensured invalid options and strategy constraints are consistently handled, improving optimization accuracy and maintainability. Enhanced logging for better debugging and diagnostics.(ref. #62)
Simplify and modularize the combination filtering and validation logic for long and short butterfly spreads. Removed redundant tests and methods to improve code clarity and reusability. Enhanced maintainability by consolidating filtering logic into `filter_combinations`. (ref. #62)
Introduced a unified `filter_combinations` method to streamline option filtering and validation logic for both Short and Long Straddle strategies. Removed redundant methods like `is_valid_short_option`, `is_valid_long_option`, and `are_valid_prices`. This simplifies code readability, reduces duplication, and improves maintainability.(ref. #62)
Revised the internal representation of positions for better clarity and consistency, changing long_call_itm/otm to long_call and short_call_low/high. Adjusted logic for validations, profit calculations, and option interactions to align with the new structure. Removed outdated tests and added modifications to reflect these updates. (ref. #62)
Streamline the `ShortStrangle` and `LongStrangle` optimization processes by introducing a reusable `filter_combinations` function, improving efficiency and clarity. Removed redundant validations and refactored chart point generation for better consistency. Updated tests to align with the new strategy validation logic, ensuring correctness. (ref. #62)
Eliminated unused and outdated test cases from `bear_put_spread.rs`, `call_butterfly.rs`, and `iron_condor.rs`. This cleanup improves maintainability by focusing on relevant and correctly functioning tests. Adjusted remaining test assertions for consistency with updated strategy logic. (ref. #62)
Refreshed the visuals for the bull call spread profit/loss chart and the intrinsic value chart. The updates ensure improved clarity and accuracy in representation.
This commit integrates the logging of Greeks for better strategy debugging and analysis. Additionally, some parameter adjustments and minor refactoring have been made for consistency and improved code clarity. (ref. #62)
Updated strategy examples to use `ZERO` for short quantities for clarity. Enhanced the `OptionChain` example by adding additional parameters to the constructor, preparing for extended functionality.
Updated the short_quantity value from `2.0` to `97.8` to ensure correct calculations in the call butterfly strategy. Additionally, added a missing close_fee entry to maintain consistency in the input parameters.
…_combinations-Method-for-All-Remaining-Strategies Feature/#62 implement filter combinations method for all remaining strategies
This commit introduces extensive unit tests for the BearCallSpread strategy, covering validation, profit/loss calculations, position integrity, and optimization logic. It ensures robustness by testing edge cases, different input scenarios, and error handling. (ref. #67)
This commit introduces comprehensive tests to validate the filtering logic for Bear Put Spread strategies. It ensures correct handling of valid/invalid combinations, pricing constraints, empty option chains, and different optimization criteria. These tests improve the reliability and robustness of the strategy implementation. (ref. #67)
…s-for-Optimizable-Trait-Implementation Feature/#67 create unit tests for optimizable trait implementation
Cleaned up formatting inconsistencies and enhanced code readability across strategy implementations and tests. Additionally, introduced new modularized unit test files for better organization and extended testing capabilities. (ref. #66)
Replaced `println!` statements with `tracing::info` in multiple examples and modules for better logging consistency. Removed an unused test file and added several new unit tests for strategies such as Iron Condor and Butterfly Spread to enhance coverage. (ref. #66)
Updated the Makefile to set LOGLEVEL to WARN when running tests. This reduces noise in test output by suppressing non-critical log messages, improving clarity during execution.(ref. #66)
Introduced a new module for testing various "optimal" trading strategies. This includes a range of strategies like butterfly spreads, iron condors, and custom strategies, ensuring comprehensive coverage and modular organization. Updated the test suite to include the `optimal` module. (ref. #66)
Refactored `process_n_times_iter` to leverage Rayon for parallel processing of combinations, significantly enhancing performance. Added `Send` and `Sync` bounds to ensure thread safety and wrapped the closure in a `Mutex` to safely handle `FnMut` in parallel contexts. (ref. #66)
This commit introduces unit tests for multiple options trading strategies, including poor man's covered call, straddles, strangles, butterfly spreads, condors, and a custom strategy. Each test ensures the correct calculation of profit areas and ratios using realistic data and configurations. (ref. #66)
Streamline combination filtering and optimize strategy creation by introducing reusable methods and removing redundant code. Enhancements include improved validation, dynamic leg grouping, and added test coverage to ensure robustness of the updated logic. (ref. #66)
…-examples-to-Integration-Tests Feature/#66 convert strategy examples to integration tests
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Release Notes: Version 0.2.5 - Advanced Strategy Optimization and Integration
Summary
This release focuses on enhancing options trading strategies by introducing integration tests, refining optimization logic, and expanding delta-neutrality support. The update also includes significant improvements to test coverage, performance, and maintainability, with optimizations leveraging parallel processing and reusable code patterns.
What's New
Enhancements
process_n_times_iterusing parallel processing (via Rayon), improving performance for combination analysis.tracing::inforeplacingprintln!for consistent debug output.OptionChaininitialization with support for parameters like risk-free rate and dividend yield.Bug Fixes
Breaking Changes
StrategyLegsenum, replacing individual leg parameters in strategy creation.StrategyLegsstructure.filter_combinationslogic now central to all strategies, necessitating adaptation in any custom implementations.Documentation Updates
Migration Notes
StrategyLegsenum for position handling.Acknowledgments
Special thanks to contributors for implementing robust delta-neutrality features, expanding integration tests, and improving documentation.
Release Links