Scaled Order Sizing and Take Profit Target ArraysWOAH Order Scaling!
This Provides a user with methods to create a list of profit targets and order sizes which grow or shrink. For size, the will add up to specific sum. for Targets they will include the first and last, and can lean towards either, to scale the order grid.
And thanks to @Hoanghetti for the markdown, i've included a basic usage example within the hover , o you don't need to search for the usage example, simply import, and when writing, the code hint contains a full example.
scaled_sizes(total_size, count, weight, min_size, as_percent)
create an array of sizes which grow or shrink from first to last
which add up to 1.0 if set the as_percent flag , or a total value / sum.
Parameters:
total_size : (float) total size to divide ito split
count : (int ) desired number of splits to create
weight : (float) a weight to apply to grow or shrink the split either towards the last being most, or the first being most, or 1.0 being each is equally sized as 1/n count
min_size : (float) a minimum size for the smallest value (in value of ttotal_size units)
as_percent : (float) a minimum size for the smallest value (in value of total_size units)
Returns: Array of Sizes for each split
scaled_targets(count, weight, minimum, maximum)
create a list of take profitt targets from the smallest to larget distance
Parameters:
count : (int ) number of targets
weight : (float) weight to apply to growing or shrinking
minimum : (float) first value of the output
maximum : (float) last value of the output
Returns: Array of percentage targets
Ordersize
PhinkTrade Risk Manager EssentialsHello there, fellow traders!
So, happy to bring you a new, free tool: my Risk Manager Essentials .
(To use it, click on "Add to favorite indicators" below, and then look for it in your charts’ "Indicators & Strategies" dialog window, inside "Favorites" tab.)
The main objective of this indicator is to help and incentivize as many traders as possible to adopt essential risk management practices .
First and foremost, it helps you define how much you can buy or sell, at your chosen price levels, in order to keep your risk always under control (in other words: in order to limit the amount you can potentially lose with a trade if your stop loss order is hit).
This is fundamental if you want to have a lasting and successful trading career: protect your capital, always . Because without it, you know: it’s game over.
Indicator also helps you visualize where minimum ideal target / take profit level is , given your risk, using the popular 3:1 Return/Risk ratio (R/R) .
3:1 R/R ratio is popular because with it you only need to “be right” (have price reach your targets) about 33% of the time, in order to be profitable : in other words, the fewer successful trades will pay you more than the sum of your unsuccessful ones will take from you.
So, make sure your strategy has a success rate greater than 33% and apply 3:1 R/R to your trades . This indicator will help you that, and with developing the necessary discipline . For example, by knowing where the ideal target should be, given your choices, you can assess the likelihood of it being reached in current price context. If that would look like a hard to happen scenario, it would probably be a good idea to avoid taking that particular trade.
Now, let’s see how it works:
When you deploy the indicator to the chart for the first time, you’ll be asked to define:
Your 1st entry price (interactively: you can define and adjust levels directly on the chart, thanks to the new Interactive Mode introduced by TradingView (ty, TV team!))
Your stop loss price (likewise)
Your 1st target price (likewise)
Your starting capital (via initial Input dialog)
Your risk (likewise)
Your risk is how much of your starting capital you are willing to lose if your stop loss is hit (define it as a % of your starting capital).
There’s a good practice here too: to risk only 1 percent of your capital per trade . This way, you can reinforce the odds of making more money than you lose and keep your peace of mind in all trades – and avoid messing up with your plans – and statistics – along the way.
Successful trading is a statistics-based endeavor. So, you want to implement and maintain consistency. Again, this indicator helps with that.
After initial setup:
You can also define additional entries and targets (up to 3 each) . Just open indicator’s Settings window and adjust accordingly.
If you have more than one entry – or target, the amounts involved will be split evenly between them. You can also enable the display of the Average Entry and Average Target labels , to see the equivalent, should you have taken (or take) a single order for each.
You can also define (via Settings, then interactively) a particular date and time for the trade . This way, labels will be presented near that moment, instead of constantly show near the latest bar.
Finally, you can personalize some other display settings: levels precision (number of decimal places), labels positions , and labels colors .
In conclusion:
You are very welcome to check it out – and adopt it on your daily use!
Please let me know your feedbacks as well. If you find any issues, or have any suggestions, I’ll be glad to hear. You can contact me here, via TradingView, or Telegram.
Finally, check the updates section below , as new stuff may show from time to time.
Thank you very much for your attention, and enjoy!
PhinkTrade