Comments (5)
Hi Valdimir,
Thanks for your interest in the project, you are right in that it is possible to run a backtest without "leg1_delta" parameter. However, my intention here is that even though you can theoretically use any parameter, when creating spreads there should be at least one parameter that specifies approximately where the legs should be. These parameters can relate to delta, price percentage, spread price, etc.
I happen to chose delta as i thought it would be the most likely used param to specify such information. I am open to expanding it, perhaps it would better to whitelist certain params that makes sense for the spread?
from optopsy.
The problem with a delta is that it usually finally known only after the market is closed. So it's not the most reliable parameter to specify the spread.
I'd rather use price-related parameters (price percentage, spread price, leg price, etc) for minimal required parametes.
from optopsy.
Do you happen to have intraday options data to test with? I have EOD options data, so delta would have been calculated and usable for me.
from optopsy.
I use EOD data as well. The problem is that all greeks in the EOD dataset are recalculated after market close. That means that we can figure out the where or not the spread should be open only when the market is close already.
Using price percentage/spread price and other price-related parameters will be more realistic, imho
from optopsy.
Good point,
i will turn this into an issue and address this in a future release.
from optopsy.
Related Issues (20)
- Short put spreads have wrong ratios assigned
- unable to import optopsy HOT 5
- Wrong Bid/Ask prices used to calculate entry/exit prices when using "market" mode
- Implement Iron Condor Strategy
- TypeError: long_call_spread() missing 2 required positional arguments: 'end' and 'filters' HOT 1
- Remove get function, move data validation to strategy function
- long_call() takes 1 positional argument but 2 were given HOT 2
- Improvement idea HOT 3
- running strategies/sample_spx_strategy.py sample failed issue HOT 2
- argument issue in sample_spx_strategy.py issue HOT 1
- Branch code-rewrite throws Error (Missing optopsy.orders module)
- Still active? HOT 6
- Include Stress testing?
- How to inject custom entry/exit dates? HOT 1
- Load from a dataframe ends in AttributeError: 'Index' object has no attribute 'remove_unused_levels' HOT 3
- Additional entry/exit conditions HOT 1
- Planned work as mentioned in the README HOT 1
- _remove_invalid_evaluated_options
- SPX singles examples generates empty output 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 optopsy.