FakhruddinFazil

Trade Information Box

FakhruddinFazil Cập nhật   
This script is a TradingView indicator written in Pine Script. It creates an information box on the chart that provides details related to a trade, including entry plan, stop loss, take profit, and position sizing. Let's break down the components:

1. **Input Parameters:**
- `entryPrice`: The entry price for the trade. This is a manually input value, and the default is set to 100.
- `smaLength`: The length parameter for the Simple Moving Average (SMA) calculation. Default is set to 20.
- `smaMultiplier`: The multiplier used to calculate the stop loss and take profit based on the SMA. Default is set to 1.5.
- `riskPerTradePercent`: The percentage of risk per trade as a decimal. Default is set to 2.
- `capital`: The total capital available for trading. Default is set to 10,000.

2. **Calculations:**
- `smaValue`: Calculates the Simple Moving Average based on the closing prices with the specified length (`smaLength`).

- `stopLoss`: Calculates the stop loss level by subtracting the product of the SMA value and the multiplier (`smaMultiplier`) from the entry price.

- `takeProfit`: Calculates the take profit level by adding the product of the SMA value and the multiplier (`smaMultiplier`) to the entry price.

- `riskPerTrade`: Calculates the actual risk amount per trade based on the specified percentage of capital.

- `maxQuantity`: Calculates the maximum quantity of shares or contracts that can be bought based on the specified risk percentage and the difference between entry price and stop loss.

- `buyValue`: Calculates the total value of the position based on the maximum quantity and entry price.

3. **Info Box:**
- `labelBox`: Defines a label box on the chart.
- `label.set_xy(labelBox, bar_index, high)`: Sets the position of the label box to the high of the current bar.
- `label.set_text(...)`: Defines the text content of the label box, providing details on the trading plan, entry, stop loss, take profit, capital, risk per trade, maximum quantity, and buy value.

Overall, this indicator is designed to provide traders with key information related to their trade plan, risk management, and position sizing directly on the chart. The displayed values are formatted with three decimal places for clarity.
Phát hành các Ghi chú:
Add ATR value in information box
Phát hành các Ghi chú:
Add LIMIT ENTRY value in information box
Phát hành các Ghi chú:
update ':' in info box
Phát hành các Ghi chú:
update box colour
Phát hành các Ghi chú:
How to Use:

1. Insert this script into TradingView's Pine Editor.
2. Set the input parameters according to your trading plan.
3. The indicator will display an information box on the chart with details about your trade plan, position sizing, and ATR.
4. Use the displayed information to make informed trading decisions.

Note: Always use proper risk management and thoroughly understand the parameters before using any trading script. This script is a tool to assist in planning trades and is not a guarantee of profitable outcomes.
Phát hành các Ghi chú:
change name to Trading Plan & Position Sizing
Phát hành các Ghi chú:
change name to: TradingPlan&Position Sizing

Mã được bảo vệ
Tập lệnh này được xuất bản mã nguồn đóng và bạn có thể sử dụng một cách tự do. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ. Bạn không thể xem hoặc sửa đổi mã nguồn.
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 đồ?