PROTECTED SOURCE SCRIPT
已更新 InitialBalance

# Initial Balance Indicator
## Overview
The Initial Balance indicator visualizes the price range (High and Low) established during a specific user-defined session time (e.g., the first hour of the trading day). It plots three key levels:
- **IB High**: The highest price reached during the session.
- **IB Low**: The lowest price reached during the session.
- **IB 50%**: The mid-point between the High and Low.
## Features
- **Custom Session Times**: Users can define the specific start and end times for the Initial Balance period (input as `HHMM`). **Note: Times are fixed to the `America/New_York` timezone.**
- **Real-Time Updates**: The levels dynamically update as the session progresses.
- **Session Independence**: Each trading day/session is treated independently using a struct-based data structure, preserving the historical lines for previous days on the chart.
- **Visual Customization**:
- Customizable colors for High (Green), Low (Red), and Mid (White) lines.
- Customizable background fill color and transparency between the High and Low lines.
## Usage
1. **Add to Chart**: specific the file `InitialBalance.pine` to your TradingView Chart.
2. **Configure Inputs**:
- **Session Settings**: Set your desired `Start Time` and `End Time` (default: 09:30 - 10:30). These times are interpreted in the **America/New_York** timezone.
- **Visual Settings**: Adjust line colors and background fill to your preference.
## Overview
The Initial Balance indicator visualizes the price range (High and Low) established during a specific user-defined session time (e.g., the first hour of the trading day). It plots three key levels:
- **IB High**: The highest price reached during the session.
- **IB Low**: The lowest price reached during the session.
- **IB 50%**: The mid-point between the High and Low.
## Features
- **Custom Session Times**: Users can define the specific start and end times for the Initial Balance period (input as `HHMM`). **Note: Times are fixed to the `America/New_York` timezone.**
- **Real-Time Updates**: The levels dynamically update as the session progresses.
- **Session Independence**: Each trading day/session is treated independently using a struct-based data structure, preserving the historical lines for previous days on the chart.
- **Visual Customization**:
- Customizable colors for High (Green), Low (Red), and Mid (White) lines.
- Customizable background fill color and transparency between the High and Low lines.
## Usage
1. **Add to Chart**: specific the file `InitialBalance.pine` to your TradingView Chart.
2. **Configure Inputs**:
- **Session Settings**: Set your desired `Start Time` and `End Time` (default: 09:30 - 10:30). These times are interpreted in the **America/New_York** timezone.
- **Visual Settings**: Adjust line colors and background fill to your preference.
版本注释
New Features:- Range Label: Added a dynamic label showing the range size in points and percentage. It intelligently positions itself above the High or below the Low depending on which extreme was established first.
- Price Levels: Added optional labels for High, Low, and Mid prices.
- Settings: Added inputs to toggle these labels and control the position of price tags (Left vs. Right side).
受保护脚本
此脚本以闭源形式发布。 但是,您可以自由使用,没有任何限制 — 了解更多信息这里。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
受保护脚本
此脚本以闭源形式发布。 但是,您可以自由使用,没有任何限制 — 了解更多信息这里。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。