shaneaus

Trailing Candle Counter

This script is for users who like to monitor and/or analyze a specified number of candles within the time the last candle closed. Al Brooks fans may enjoy this indicator.

While searching for an indicator that already had this functionality I found a script by @Steversteves which counted the candles/percentage within a set period of time. This let me know it could be done. In honor of Steversteves I kept the table the same colors - although, I added code to allow the table to be modified.

When opening the script the user will need to set a begin/end time to analyze – don't worry as you can set anything you want and it can be altered after the script is running.

This image shows the settings for a user to be able to set a begin time and have the indicator count all the candles from that time through to the current time and update at each candle close. The user can move the beginning time as needed. This is useful if the user is monitoring the length of a trend, wedge, channel, etc.:
If the indicator is in view and the beginning time is on the chart the user can select the table to view/select/change the beginning time.

This image shows the settings for a user to monitor the last set of candles since the last candle closed. This is useful if the user expects a pullback after a set number of candles or expects some alteration in a trend within a set number of candles. In this case the user setting is to watch five candles:

This setting is the reason for my creation of this indicator. This image shows the settings for a user to monitor two sets of candles. In this case an additional set of five candles has been added to the original set of five candles:
If one is watching for movements to last a certain number of bars when the first bar of the movement is exiting the background color the user can expect a change in the price momentum.

This image shows the same functionality as in Steversteves original script (although, I used almost none of his original code). The user can set a begin time and end time to analyze the number or red/green candles and the percentage of each within that time period.
If the indicator is in view and the beginning and end times are on the chart the user can select the table to view/select/change the times.

I hope you find this useful and if you have any questions/comments/suggestions for improvement please comment below.
Mã nguồn mở

Với tinh thần TradingView, tác giả của tập lệnh này đã xuất bản nó dưới dạng mã nguồn mở, vì vậy các nhà giao dịch có thể hiểu và xác minh nó. Chúc mừng tác giả! Bạn có thể sử dụng mã này miễn phí, nhưng việc sử dụng lại mã này trong một ấn phẩm chịu sự điều chỉnh của Nội quy nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Thông báo miễn trừ trách nhiệm

Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?