gnelabs / NateTradeOpeningRange

Opening range trading strategy
Apache License 2.0
1 stars 0 forks source link

Add volatility indicator #4

Closed gnelabs closed 5 months ago

gnelabs commented 5 months ago

Using options data, calculate the average volatility for the security. Since this is an intraday strategy, if possible calculate this vol using at the money options for the shortest possible expiration. This will be closer to mimicking intraday moves.

gnelabs commented 5 months ago

It looks like this can be done if some simple assumptions are made. Example:

SELECT implied_volatility
FROM `options`.`greeks`
WHERE timestamp_utc BETWEEN 1713817830 AND 1714422630
AND ticker = 'NVDA'
AND expiration = '2024-05-03'
AND strike > (underlying  * 0.9)
AND strike < (underlying * 1.1)

Gets a vol surface for strikes up to 10% out of the money, so relatively at the money. I'll probably need to use whatever the monthlies expiration is since not everything is guaranteed to have weeklies.

gnelabs commented 5 months ago

https://github.com/gnelabs/NateTradeOpeningRange/commit/96007281d4f870db5ee1bbee04075f225c8e2846