AlphaBotSystem

Alpha Performance of Period

Alpha Performance of Period (PoP) produces a visualization of returns (gains and losses) over a quarterly, monthly, or annual period. It also displays the total % gain and loss over any length of days, months, and years as defined by the user.

Performance of Period (PoP) can be used to understand the performance of an asset over multiple periods using a single chart layout, and to compare the performance of different assets by using a multi-chart layout.

This can, for example, be used to compare the NASDAQ, S&P, and DJI over the past 20 years to create a dow vs. nasdaq vs. s&p performance chart. This can help you understand a comparison of historical returns by showing which performs the best month-over-month, quarter-to-quarter, year-to-year, throughout any custom period of days/months/years.

The ability to get a visualization of the % gain/loss can help to better understand how markets have performed over time and which markets have historically performed the best.

Check out the up and coming Educational Idea we will be releasing soon after this is live to see an example of how we use this tool.





Current Period Label
-----
Current Period: This label shows the current period's performance only when you hover over it.
(This label is located to the left of the current period's open candle and at the current candles close price)


TICKER "Time Period" Performance Label
-----
Total Period Gain: The total of all % gain periods from the start to end date.
Largest Period Gain: The biggest % gain period from the start to end date.

Total Period Loss: The total of all % loss periods from the start to end date.
Largest Period Loss: The biggest % loss period from the start to end date.

Total period Performance: The total % performance, the difference between the total gain and total loss.

NOTE: The "Current Period" performance is excluded from ALL five of the above-mentioned figures. This was done to avoid giving inaccurate comparison figures due to the period not being finished yet.





Inputs
-----
Current Script Version + Info: A drop-down list of instructions for the user to refer to.

Dark Mode Labels: Toggle on for Dark Mode. This is done since Labels text and background color can not be adjusted separately within the visual inputs so this is the best fit solution.

Time Period of Returns: Pick the period of performance you would like to emulate monthly/quarterly/annual.

Start Date: The day to start tracking performance.
Start Month: The month to start tracking performance.
Start Year: The year to start tracking performance.

End Date: The day to stop tracking performance.
End Month: The month to stop tracking performance.
End Year: The year to stop tracking performance.




As always if you have any feedback let us know in the comments and leave a like if you enjoy this tool :)
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 đồ?