Custom Trading Scripts

Your Online Source For Stock Codes

CTS Inside Bar Study

$197.00

This script is designed to identify and plot inside bars on a price chart. Inside bars are bars where the high of the current bar is lower than the high of the previous bar and the low of the current bar is higher than the low of the previous bar.

1. Inside Bar Condition:
– The script starts by defining the condition for identifying an inside bar. It checks if the high of the current bar is lower than the high of the previous bar and if the low of the current bar is higher than the low of the previous bar.

2. Plotting High of Inside Bars:
– The script identifies and plots the high of each inside bar as a horizontal line. It maintains a count of inside bars and a count of data points corresponding to high values of inside bars.

3. Plotting Low of Inside Bars:
– Similarly, the script identifies and plots the low of each inside bar as a horizontal line. It maintains a count of inside bars and a count of data points corresponding to low values of inside bars.

4. Plotting Logic:
– The script uses conditions to determine whether to plot the high and low of inside bars based on the number of inside bars and the specified plot count.

5. Styling:
– The plotted horizontal lines representing the highs and lows of inside bars are styled with a yellow color.

In summary, this script helps visualize inside bars on a price chart by plotting horizontal lines corresponding to the highs and lows of these bars. It maintains counts to limit the number of plotted lines and provides a simple way to identify inside bars within the specified parameters.

Please note that this script is for educational purposes and cannot be shared due to user agreement restrictions.