Dynamic Date and Price Tracker with Entry Price

This tool provides an intuitive graphical representation of your trade's profitability based on a custom entry date and price.
Features:
-Starting Date Selection: Choose a specific starting date, after which the indicator begins tracking your trade's performance.
-Custom Entry Price: Input a starting price to accurately reflect your actual entry price for performance tracking across different timeframes.
-Real-Time Tracking: As new bars form, the indicator automatically adjusts a dynamic line to the current closing price.
-Profit/Loss Color Coding: The dynamic line color changes based on whether the current price is above (green for profit) or below (red for loss) your specified entry price.
-Performance Label: A real-time label displays the absolute and percentage change in price since your initial entry, color-coded for positive (green) or negative (red) performance.
-Entry Price Line: The horizontal line marks your starting price for easy visual comparison.
It's meant to make your life easier, not rocket science.
Step1: Open Settings
Step 2: Enter Entry Price and Entry Date
That's it! A label is added on the chart at the current price showing the Absolute Profit/Loss.
This tool provides an intuitive graphical representation of your trade's profitability based on a custom entry date and price. Previously you would need to manually draw on the chart with 'Measure' or 'Prediction' tools in TV. This plots absolute Profit/Loss real-time so you can keep your chart nice and tidy without constantly needing to adjust your drawings. I wasn't able to find a simple enough indicator to fill this need, so I decided to make it for myself. (how it's unique)
Profit (%) = (Profit/Price) × 100
Loss (%) = (Loss/Price) × 100
(how it does it)
How to use it:
-Starting Date Selection: Choose a specific starting date, after which the indicator begins tracking your trade's performance.
-Custom Entry Price: Input a starting price to accurately reflect your actual entry price for performance tracking across different timeframes.
Features:
-Real-Time Tracking: As new bars form, the indicator automatically adjusts a dynamic line to the current closing price.
-Profit/Loss Color Coding: The dynamic line color changes based on whether the current price is above (green for profit) or below (red for loss) your specified entry price.
-Performance Label: A real-time label displays the absolute and percentage change in price since your initial entry, color-coded for positive (green) or negative (red) performance.
-Entry Price Line: The horizontal line marks your starting price for easy visual comparison.
I hope you find it as useful as I do!
-Enhanced Label Text: Updated the label text to correctly show the price change and percentage change.
-Persistent Entry Line: Added a persistent variable for the entry price line to ensure it updates correctly.
-Improved Label Color: Made the label background color semi-translucent green or red based on whether the current price is above or below the entry price.
-Optimized Code: Streamlined the update logic for lines and labels, and removed redundant calculations.
Enhancements include-
-Multiple Entries: The enhanced indicator supports tracking up to 5 different entries, whereas the old indicator only tracks one entry.
-Entry Shares: It allows for specifying the number of shares for each entry, enabling accurate dollar gain/loss calculations.
-Gain/Loss Calculations: The enhanced indicator calculates both dollar and percentage gain/loss for each entry.
-Label Customization: Users can choose to display either dollar gain/loss, percentage gain/loss, or both on the labels.
-Dynamic Label Colors: Labels and lines change color based on whether the current price is above or below the entry price.
-Comprehensive Overview: It includes a table displaying the total gain/loss across all entries in the selected position on the chart, as well as two chart positions.
-Enhanced Visualization: It uses dotted lines to visually connect entry points with current price levels, much easier on the eyes.
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Untuk akses pantas pada carta, tambah skrip ini kepada kegemaran anda — ketahui lebih lanjut di sini.
Penafian
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Untuk akses pantas pada carta, tambah skrip ini kepada kegemaran anda — ketahui lebih lanjut di sini.