OPEN-SOURCE SCRIPT
Atualizado Risk Manager & Position Sizer

A comprehensive Risk Management and Position Sizing tool that visually plots Risk: Reward levels on your chart and provides a real-time data dashboard.
Features
Dual Risk Calculation: Toggle between risking a fixed percentage of your total capital or a specific cash amount.
Visual Trade Planner: Includes draggable entry, stop-loss, and take-profit lines with automatic R:R fill boxes (Profit/Loss zones).
Real-Time Dashboard: A clean, customizable table that calculates:
Position Size (Qty): Exact units to buy/sell based on your risk.
Portfolio Weight: How much of your total capital the trade consumes.
Breakeven Price: Calculates the price needed to cover commission costs.
ATR Volatility Stop: Provides a secondary stop-loss suggestion based on current market volatility (ATR).
Live P&L: Tracks your theoretical profit or loss based on current price action.
Fully Customizable: Toggle visibility for every metric and adjust colours, line styles, and table positioning to fit your chart layout.
How to Use
1. Primary Inputs: Enter your Total Capital and your desired Risk (e.g., 1% or $100).
2. Trade Setup: Select "Long" or "Short" and use the price icons (⌖) in the settings to pick your Entry, Stop, and Target levels directly from the chart.
3. Position Sizing: Look at the "Quantity" or "Position Value" in the dashboard to know exactly how much to trade.
4. Commission: Adjust the Commission % in the "Costs" section to get an accurate Breakeven price.
Disclaimer
This script is for educational and informational purposes only. It is designed to assist with position sizing calculations based on user-defined inputs. It does not provide financial advice, buy/sell signals, or guarantee profits. Trading involves significant risk, and you should always perform your own due diligence. The author is not responsible for any financial losses incurred through the use of this tool.
Features
Dual Risk Calculation: Toggle between risking a fixed percentage of your total capital or a specific cash amount.
Visual Trade Planner: Includes draggable entry, stop-loss, and take-profit lines with automatic R:R fill boxes (Profit/Loss zones).
Real-Time Dashboard: A clean, customizable table that calculates:
Position Size (Qty): Exact units to buy/sell based on your risk.
Portfolio Weight: How much of your total capital the trade consumes.
Breakeven Price: Calculates the price needed to cover commission costs.
ATR Volatility Stop: Provides a secondary stop-loss suggestion based on current market volatility (ATR).
Live P&L: Tracks your theoretical profit or loss based on current price action.
Fully Customizable: Toggle visibility for every metric and adjust colours, line styles, and table positioning to fit your chart layout.
How to Use
1. Primary Inputs: Enter your Total Capital and your desired Risk (e.g., 1% or $100).
2. Trade Setup: Select "Long" or "Short" and use the price icons (⌖) in the settings to pick your Entry, Stop, and Target levels directly from the chart.
3. Position Sizing: Look at the "Quantity" or "Position Value" in the dashboard to know exactly how much to trade.
4. Commission: Adjust the Commission % in the "Costs" section to get an accurate Breakeven price.
Disclaimer
This script is for educational and informational purposes only. It is designed to assist with position sizing calculations based on user-defined inputs. It does not provide financial advice, buy/sell signals, or guarantee profits. Trading involves significant risk, and you should always perform your own due diligence. The author is not responsible for any financial losses incurred through the use of this tool.
Notas de Lançamento
Added 5-section organization, dynamic table visibility, and fixed trailing stop logic.Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.