-
-
Notifications
You must be signed in to change notification settings - Fork 166
API Reference
All functions defined in this page have the following common parameters:
- data (pandas.DataFrame, required): Pandas DataFrame containing the data to generate calls strategies for
- dte_interval (int, default: 7): An integer representing the amount of days to group by, used for "Days to Expiration"
- max_entry_dte (int, default: 90): An integer representing the max days to expiration on entry to consider
- exit_dte (int, default: 0): An integer representing the days to expiration on exit, defaults to exit on expiration date
- otm_pct_interval (float, default: 0.05): A percentage numeral representing the OTM percent to group generated strategies by. (formula: (strike - underlying price) / strike)
- max_otm_pct (float, default: 0.5): Maximum OTM percentage to consider when generating strategy
- min_bid_ask (float, default: 0.05): The smallest bid/ask price to consider on entry. This is generally the price at which the option is considered worthless
- drop_nan (bool, default: True): Remove rows where NaN were returned, likely due to insufficient data
- raw (bool, default: False): Return only generated trades for the specified option strategy without grouping by dte_interval and otm_pct_interval. It's not recommend to set this parameter to True, as large amounts of trades maybe generated depending on strategy
All statistics generated from Optopsy functions below are for percentage change
Generates all combinations of long call strategies on the specified dataset.
Generates all combinations of short call strategies on the specified dataset.
Generates all combinations of long put strategies on the specified dataset.
Generates all combinations of short put strategies on the specified dataset.
Generates all valid combinations of long straddles on the specified dataset.
Generates all valid combinations of short straddles on the specified dataset.
Generates all valid combinations of long strangles on the specified dataset.
Generates all valid combinations of short strangles on the specified dataset.
Generates all valid combinations of long call spreads on the specified dataset.
Generates all valid combinations of short call spreads on the specified dataset.
Generates all valid combinations of long put spreads on the specified dataset.
Generates all valid combinations of short put spreads on the specified dataset.
Copyright © 2020, Michael Chu