ATH Gain PotentialThe indicator quantifies the relative position of a symbol's current closing price in relation to its historical all-time high (ATH).
By evaluating the ratio between the ATH and the present closing price, it provides an analytical framework to estimate the potential gains that could accrue if the symbol were to revert to its ATH from a specified reference point. The ratio serves as a quantitative measure for assessing the distance between the current market value and the symbol's historical peak, enabling investors to gauge the prospective profitability of a return to the ATH.
Gains
Position TrackerEnter your purchase price & the quantity.
It'll display a line at that value, with a label indicating the current gain/loss
Potential Gain/Loss IndicatorThis indicator calculates the gains and losses in percentage based on the highest high (ATH) and lowest low (ATL) of a given period. It takes the period as an input parameter and calculates the ATH and ATL within that period.
The indicator then calculates the potential gains in percentage if the price goes back to the ATH, as well as the potential losses in percentage if the price goes back to the ATL.
A filled area chart is plotted to show the difference between gains and losses (gains - losses) using a stepline, with green color when positive and red color when negative. The coefficient parameter allows for adjusting the scale of the gains and losses.
# Parameters
1. `period` (integer): The period used for calculating the highest high (ATH) and lowest low (ATL) within the given range. The default value is 50, and the user can select any value greater than or equal to 1.
2. `coef` (float): A coefficient to adjust the scale of the gains and losses. The default value is 0.5, and the user can select any value greater than or equal to 0.1.
Gain/StopLoss Percentage LinesGain/StopLoss Percentage Lines is a quick way to enter your Entry Price in to a stock and track the percentage of gain or loss at the 5% and 10% markers.
Click on the gear settings icon and type in your entry price. The percentage is defaulted to 5%. You can change this to a different percentage at this screen. Note that whatever number you enter will be doubled for the upper and lower lines. For instance, if you want to set your first red line stop loss and green gain line at 2.5%, your two other upper and lower green and red lines will be at 5%.
However, this will not change the text on the tab marker.
To change the tab text, go in to the Pine Editor and change the green text that says "5% Gain" and "5% Loss" to your new percentages.
Moving Gain Loss PercentTracks the percentage gain/loss in three ranges:
single candle (can be turned on or off)
custom range of candles
custom range of candles
For example, with a range of 3 candles, and the serie:
1 - close 10
2 - close 5
3 - close 20
The moving gain would be:
1 - close 10 - gain 10, infinite%
2 - close 5 - gain 5, infinite%
3 - close 18 - gain 8, 80%
Or, for example if the range is 12 candles on a monthly chart, then the result is the Year-To-Date gain/loss plotted as a percentage.