Theta Shield | Flux Charts💎 GENERAL OVERVIEW
Introducing our new Theta Shield indicator! Theta is the options risk factor concerning how fast there is a decline in the value of an option over time. This indicator aims to help the trader avoid sideways market phases in the current ticker, to minimize the risk of theta decay. For more information, please check the "How Does It Work" section.
Features of the new Theta Shield Indicator :
Foresight Of Accumulation Zones
Decrease Risk Of Theta Decay
Clear "Valid" & "Non-Valid" Signals
Validness Trail
Alerts
📌 HOW DOES IT WORK ?
In options trading, theta is defined as the rate of decline in the value of an option due to the passage of time. Traders want to avoid this kind of decay in the value of an option. One of the best ways to avoid it is not holding an option contract when the market is going sideways. This indicator uses a stochastic oscillator to try to get a foresight of sideways markets, warning the trader to not hold an option contract while the price is in a range.
The indicator starts by calculating the stochastic value using close, high & low prices of the candlesticks. Then a stoch threshold & a theta length are determined depending on the option contract type defined by the user in the settings of the indicator. Each candlestick that falls above or below the stoch threshold value is counted, and a "theta valid strength" is calculated using the counted candlesticks, which has a value between -100 & 100. Here is the formula of the "theta valid strength" value :
f_lin_interpolate(float x0, float x1, float y0, float y1, float x) =>
y0 + (x - x0) * (y1 - y0) / (x1 - x0)
thetaValid = Total Candlesticks That Fall Above & Below The Threshold In Last "Theta Length" bars.
thetaValidStrength = f_lin_interpolate(0, thetaLength, -100, 100, thetaValid)
Then a trail is rendered, and "Valid" & "Non-Valid" signals are given using this freshly calculated strength value. Valid means that the indicator currently thinks that no accumulation will happen in the near future, so the option positions in the current ticker are protected from the theta decay. Non-Valid means that the indicator thinks the ticker has entered the accumulation phase, so holding any option position is not recommended, as they may be affected by the theta decay.
🚩 UNIQUENESS
This indicator offers a unique way to avoid theta decay in options trading. It uses a stochastic oscillator and thresholds to calculate a "theta strength" value, which is used for rendering validness signals and a trail. Traders can follow the valid & non-valid signals when deciding to hold their options position or not. The indicator also has an alerts feature, so you can get notified when a ticker is about to enter a range, or when it's about to get out of it.
⚙️ SETTINGS
1. General Configuration
Contract Type -> You can set the option contract type here. The indicator will adjust itself to get a better foresight depending on the contract length.
2. Style
Fill Validness -> Will render a trail based on "theta strength" value.
Optionstrader
BUY/SELL + ADVANCE DECLINEThis script is a custom trading view indicator that helps to identify potential buy and sell signals based on the RSI (Relative Strength Index) and SMA (Simple Moving Average) indicators. The script also identifies potential reversals using a combination of RSI and price action. It plots buy, sell, and reversal signals on the chart along with an SMA line. Additionally, it provides alerts based on the buy, sell, and reversal conditions.
Changes made to the original script:
Fixed the undeclared identifier 'c' error by calculating the difference between the current closing price and the previous closing price: c = close - close .
Added an "ADD Value Floating Label" to the chart. The label shows the difference between the current and previous closing prices (ADD value) along with a "Bullish" or "Bearish" indicator based on the value of 'c'. The label is positioned at the top right of the visible chart area and remains static.
Here's a summary of the major components of the script:
Input settings: Define the input parameters for RSI and SMA.
Calculation of RSI and SMA: Compute the RSI and SMA values based on the input parameters.
Color definitions: Define colors for different conditions and levels.
Condition definitions: Define various conditions for buy, sell, reversal, and other criteria.
Buy and sell conditions: Determine buy and sell signals based on RSI, SMA, and price action.
Reversal conditions: Identify potential reversals using RSI and price action.
Plot signals: Display buy, sell, and reversal signals on the chart.
Bar colors: Color the bars based on the identified signals.
Plot SMA: Display the SMA line on the chart.
Alert conditions: Set up alerts for buy, sell, and reversal conditions.
ADD Value Floating Label: Add a label to the chart showing the ADD value and a "Bullish" or "Bearish" indicator.
Automated Option Price - Black-Scholes modelPlease make sure you are plotting this indicator on DAILY bars, not doing so will lead to unintended results. Also, make sure that you keep up to date the Risk-free interest rate, which you can consult (for U.S.) on ycharts.com.
This is an indicator that is meant to be used for Options Day Trading, but it can be useful for mid-term or leaps for I also enabled the possibility for user to input manually the Strike and Expiration date. I based the calculation on the Black-Scholes model. Variables included in the calculation are:
-Stock price (S): The current price of the underlying asset (e.g., a stock).
-Strike price (K): The predetermined price at which the option can be exercised.
-Time to expiration (T): The time remaining until the option expires, expressed as a fraction of a year.
-Volatility (σ): The annualized standard deviation of the stock's returns, which is a measure of the stock's price fluctuations.
-Risk-free interest rate (r): The annualized return on a risk-free investment, often approximated by the yield on a government bond.
The only variable I excluded from the original model was the Dividend yield (q).
U S E R I N P U T S:
1. AUTOMATIC calculations enabled:
i) Strike price (K):
Automatically calculate the strike price for both call and put options based on the stock's closing price. The logic follows a set of rules to determine the strike prices which will usually be Out-of-the-Money (OTM):
-If the stock's closing price is between 1 and 60, the call strike price is rounded up to the nearest whole number, while the put strike price is rounded down to the nearest whole number.
-If the stock's closing price is between 60 and 90, the call strike price is rounded up to the nearest whole number and increased by 1, while the put strike price is rounded down to the nearest whole number and decreased by 1.
-If the stock's closing price is between 90 and 120, the call strike price is rounded up to the nearest whole number and increased by 2, while the put strike price is rounded down to the nearest whole number and decreased by 2.
-If the stock's closing price is above 120, the call strike price is rounded up to the nearest multiple of 5, while the put strike price is rounded down to the nearest multiple of 5.
By applying these rules, I just tried to ensure that the automatically calculated strike prices are tailored to the stock's price range, allowing for more accurate option pricing calculations.
ii) Time to expiration (T):
The indicator will consider this week’s expiration contracts (Friday) only when the current day/bar = Monday. If Tuesday or older it will consider the expiration date of the next week’s Friday (because we are not Theta gamblers, right?).
If you are not comfortable with above for whatever reason, you can always…
2. Enter inputs MANUALLY
First make sure you UNTICK the boxes for automatic calculation.
i) Strike price (K) – Self-explanatory
ii) Time to expiration (T) – Just make sure that the horizon you are inputting matches with the next parameter (e.g. you would not input a Monthly risk-free interest rate for a Leap).
iii) Risk-free interest rate (r) – You can pull this data from the web. Here’s the link I used to define the value that this indicator was launched with:
ycharts.com
Don’t get obsessed with updating this daily if you are using this for day trading, you will notice that weekly may be more than enough.
V O L A T I L I T Y
Not option to manually input Volatility so I’ll explain how it is calculated in this script:
I considered two measures of volatility; one is derived calculating the annualized volatility using the standard deviation of daily returns and the second one is the ATR-based annualized volatility. I then used a ‘combined’ approach with the harmonic mean and the arithmetic mean of these results which can help account for the variability in the option prices calculated with different volatility estimates, which can be more robust when dealing with outliers or skewed data. I back tested with some samples of actual option prices and found that this approach is the one that got results closer to the actual bids.
T A B L E
Nomenclature to read rows is:
Option Strike Price | Type of Option (Put or Call) @ The current Close or at 50% level of bar | Estimated Price
*The Option expiration Date showed as dd-MMM as part of the headers.
Second and third row (color 1): These will show the calculated value for the Put/Call, assuming you are buying at the CURRENT price of the stock.
Third and Fifth row (color2): These will show the calculated value for the Put/Call, assuming you buy at the 50% level of the current bar (this is the value that the contract WOULD HAVE at the 50% level of the bar).
If you plot the indicator during market hours it will obviously update as price moves, this is an intended feature.
L I M I T A T I O N S
The Black-Scholes model, like many other models, has its limitations and will oftentimes provide inaccurate option prices in all market conditions. High volatility events, such as earnings announcements, can lead to significant price fluctuations that are not fully captured by the model.
The model assumes that the stock price follows a continuous random walk with constant volatility, but in reality, volatility can change over time, and stock prices can exhibit jumps, especially around significant events like earnings announcements. This can cause the model to underestimate the true option price in such situations.
Please make sure that you first back test on the symbols you trade to ensure the information presented by this indicator will suit your trading strategy. You will find that the delta between the proposed price of the indicator versus the actual price may differ significantly in some symbols while for others it will be very close. For instance, today (13APR23), the prices for AMD, DIS, AAPL (puts only), were very close to actual bids, whereas TSLA differ significantly (but then again, take a look at the calendar and this last symbol is having earnings next week which may add a premium to the contracts)… I am sure you will get your own conclusions and applicable use cases based on the data you test with.
As always, be wise and methodical on the investment or trading decisions you make!
Higher Time Frame Average True RangesPurpose: This script will help an options trader asses risk and determine good entry and exit strategies
Background Information: The true range is the greatest of: current high minus the current low; the absolute value of the current high minus the previous close; and the absolute value of the current low minus the previous close. The Average True Range (ATR) is a 14-day moving average of the true range. Traders use the ATR indicator to assess volatility in stocks and decide when to enter and exit trades. It is important to note the limitations of using True Range and ATR: These indications cannot tell you the direction of your options trade (call vs. put) and they cannot tell you whether a particular trend is about to reverse. However, it can be used to assess if volatility has peaked for a particular direction and time period.
How this script works: This indicator calculates true range for the daily (DTR), weekly (WTR), and monthly (MTR) time frames and compares it to the Average True Range (ATR) for each of those time frames (DATR, WATR, and MATR). The comparison is displayed into a colored table in the upper right-hand corner of the screen. When a daily, weekly, or monthly true range reaches 80% of its respective ATR, the row for that time frame will turn Orange indicating medium risk for staying in the trade. If the true range goes above 100% of the respective ATR, then the row will turn Red indicating high risk for staying in the trade. When the row for a time period turns red, volatility for the time period has likely peaked and traders should heavily consider taking profits. It is important to note these calculations start at different times for each time frame: Daily (Today’s Open), Weekly (Monday’s Open), Monthly (First of the Month’s Open). This means if it’s the 15th of the month then the Monthly True Range is being calculated for the trading days in the first half of the month (approximately 10 trade days).
The script also plots three sets of horizontal dotted lines to visually represent the ATR for each time period. Each set is generated by adding and subtracting the daily, weekly, and monthly ATRs from that time periods open price. For example, the weekly ATR is added and subtracted from Mondays open price to visually represent the true range for that week. The DATR is represented by red lines, the WATR is represented by the green lines, and the MATR is represented by the blue lines. These plots could also be used to assess risk as well.
How to use this script: Use the table to assess risk and determine potential exit strategies (Green=Low Risk, Orange=Medium Risk, Red=High Risk. Use the dotted lines to speculate what a stock’s price could be in a given time period (Daily=Red, Weekly=Green, and Monthly=Blue). And don’t forget the true range’s calculation and plots starts at the beginning of each time period!
Monthly Options Expiration 2020Monthly options expiration for the year 2020.
Also you can set a flag X no. of days before the expiration date. I use it at as marker to take off existing positions in expiration week or roll to next expiration date or to place new trades.
Happy new year 2020 and all the best traders.