LUCEO BBLUCEO BB (with Dynamic Alerts)
This is an enhanced Bollinger Bands indicator designed to provide timely, clean, and highly informative alerts for key market conditions. It eliminates repetitive alert spam and provides rich, dynamic context in every notification, helping you make faster and more informed decisions.
Key Features
"First-Trigger" Alerts: Get a single, clean alert only on the first candle a condition is met. No more alert fatigue during a strong trend or a prolonged squeeze.
Three Key Conditions:
Squeeze Start: Notifies you the moment a Bollinger Band squeeze begins, signaling the potential for a significant price move.
Initial Breakout: Alerts on the first candle the price breaks above the upper band, indicating a potential start of a new uptrend.
Initial Breakdown: Alerts on the first candle the price breaks below the lower band, indicating a potential start of a new downtrend.
Dynamic & Rich Alert Messages: Alerts are automatically formatted with the Ticker, a user-friendly Timeframe (e.g., 4h, 1D), the specific event, and the current price formatted to the correct number of decimal places.
Example: BB Upper First Breakout Current Price: 65,123.5
Persistent Visual Cues: While alerts are sent only once per event, the chart background will remain colored (Yellow for Squeeze, Blue for Upper, Red for Lower) for as long as the condition persists, allowing for easy visual tracking.
How to Set Up Alerts
Add the indicator to your chart.
Click the 'Alert' icon in the TradingView toolbar.
In the 'Condition' dropdown, select LUCEO BB.
In the second dropdown, select 'Any alert() function call'. This is a critical step.
Leave the 'Message' box empty (the script provides the full message).
Click 'Create'.
Settings
BB Length: The look-back period for the Bollinger Bands.
BB StdDev: The number of standard deviations for the bands.
Squeeze Threshold (%): Defines the percentage below the average bandwidth to trigger a squeeze condition.
LUCEO BB (커스텀 동적 알림)
이 지표는 주요 시장 상황에 대해 시기적절하고, 깔끔하며, 매우 유용한 알림을 제공하도록 설계된 강화된 볼린저밴드 지표입니다. 반복적인 알림 스팸을 제거하고 모든 알림에 풍부하고 동적인 컨텍스트를 제공하여 더 빠르고 정보에 입각한 결정을 내리는 데 도움을 줍니다.
주요 특징
'최초 발생' 알림: 조건이 충족되는 첫 번째 캔들에서만 단 한 번의 깔끔한 알림을 받으세요. 강한 추세나 지속되는 스퀴즈 동안 더 이상 알림으로 피로를 느끼지 않아도 됩니다.
세 가지 핵심 조건:
스퀴즈 시작: 볼린저밴드 스퀴즈가 시작되는 순간을 알려주어 잠재적인 큰 가격 변동에 대비할 수 있습니다.
최초 상단 돌파: 가격이 상단 밴드를 처음으로 돌파하는 캔들에서 알려주어 새로운 상승 추세의 시작 가능성을 나타냅니다.
최초 하단 이탈: 가격이 하단 밴드를 처음으로 이탈하는 캔들에서 알려주어 새로운 하락 추세의 시작 가능성을 나타냅니다.
동적이고 풍부한 알림 메시지: 알림은 티커, 사용자 친화적인 시간봉(예: 4h, 1D), 특정 이벤트 및 현재 가격이 자동으로 형식에 맞춰 포함됩니다.
예시: BB 상단 첫 돌파 현재 가격: 65,123.5
지속적인 시각 신호: 알림은 이벤트당 한 번만 전송되지만, 차트 배경색(스퀴즈: 노랑, 상단: 파랑, 하단: 빨강)은 조건이 지속되는 동안 유지되어 시각적으로 쉽게 상황을 추적할 수 있습니다.
알림 설정 방법
지표를 차트에 추가합니다.
트레이딩뷰 툴바에서 '알림' 아이콘을 클릭합니다.
'조건' 드롭다운 메뉴에서 LUCEO BB를 선택합니다.
두 번째 드롭다운 메뉴에서 **'모든 alert() 함수 호출' (Any alert() function call)**을 선택합니다. 이 단계가 매우 중요합니다.
'메시지' 창은 비워둡니다 (스크립트가 자동으로 전체 메시지를 제공합니다).
'만들기'를 클릭합니다.
설정
BB Length: 볼린저밴드의 기간을 설정합니다.
BB StdDev: 밴드의 표준편차 값을 설정합니다.
Squeeze Threshold (%): 스퀴즈 상태를 감지하기 위해 평균 밴드 폭 대비 얼마나 좁아졌는지를 백분율로 설정합니다.
Indicateurs et stratégies
Multiplied and Divided Moving Average ### Multiplied and Divided Moving Average Indicator
**Description**:
The "Multiplied and Divided Moving Average" indicator is a customizable tool for TradingView users, designed to create dynamic bands around a user-selected moving average (MA). It calculates a moving average (SMA, EMA, WMA, VWMA, or RMA) and generates a user-defined number of lines above and below it by multiplying and dividing the MA by linearly spaced factors. These bands serve as potential support and resistance levels, aiding in trend identification, mean reversion strategies, or breakout detection. Optional Buy/Sell labels appear when the price crosses below the divided MAs (Buy) or above the multiplied MAs (Sell), providing clear visual cues for trading opportunities.
**Key Features**:
- **Flexible MA Types**: Choose from Simple (SMA), Exponential (EMA), Weighted (WMA), Volume-Weighted (VWMA), or Running (RMA) moving averages.
- **Customizable Bands**: Set the number of lines (0–10) above and below the MA, allowing tailored analysis for any market or timeframe.
- **Dynamic Factors**: Bands are created using factors that scale linearly from 1 to a user-defined maximum (default: 5.0), creating intuitive overbought/oversold zones.
- **Buy/Sell Signals**: Optional labels highlight potential entry (Buy) and exit (Sell) points when the price crosses the bands.
- **Clear Visuals**: The main MA is plotted in blue, with green (multiplied) and red (divided) lines using graduated transparency for easy differentiation.
**Inputs**:
- **MA Type**: Select the moving average type (default: SMA).
- **MA Length**: Set the MA period (default: 14).
- **Number of Lines Above/Below**: Choose how many bands to plot above and below the MA (default: 4, range: 0–10).
- **Max Factor**: Define the largest multiplier/divisor for the outermost bands (default: 5.0).
- **Source**: Select the price data for the MA (default: close).
- **Show Buy/Sell Labels**: Enable or disable Buy/Sell labels (default: true).
**How It Works**:
1. Calculates the chosen moving average based on user inputs.
2. Creates up to 10 lines above the MA (e.g., MA × 2, ×3, ×4, ×5 for `numLines=4`, `maxFactor=5`) and 10 below (e.g., MA ÷ 2, ÷3, ÷4, ÷5).
3. Plots the main MA in blue, multiplied lines in green, and divided lines in red, with transparency increasing for outer bands.
4. If enabled, displays "Buy" labels when the price crosses below any divided MA and "Sell" labels when it crosses above any multiplied MA, positioned at the outermost band.
**Use Cases**:
- **Trend Analysis**: Use the bands as dynamic support/resistance to confirm trend direction or reversals.
- **Mean Reversion**: Identify overbought (near multiplied MAs) or oversold (near divided MAs) conditions.
- **Breakout Trading**: Monitor price crossovers of the outermost bands for potential breakout signals.
- **Signal Confirmation**: Use Buy/Sell labels for swing trading or to complement other indicators.
**How to Use**:
1. Copy the script into TradingView’s Pine Editor.
2. Compile and apply it to your chart (e.g., stocks, forex, crypto).
3. Adjust inputs like `numLines`, `maxFactor`, or `maType` to fit your strategy.
4. Enable `Show Buy/Sell Labels` to visualize trading signals.
5. Test on various timeframes (e.g., 1H, 4H, 1D) and assets to optimize settings.
**Example Settings**:
- **Swing Trading**: Use `numLines=3`, `maxFactor=4`, `maType=EMA`, `maLength=20` on a 4-hour chart.
- **Intraday**: Try `numLines=2`, `maxFactor=3`, `maType=SMA`, `maLength=10` on a 15-minute chart.
**Notes**:
- **Performance**: Supports up to 20 bands (10 above, 10 below), staying within TradingView’s 64-plot limit.
- **False Signals**: In choppy markets, frequent crossovers may occur. Combine with trend filters (e.g., ADX, higher-timeframe MA) to reduce noise.
- **Enhancements**: Add alerts via TradingView’s alert system for Buy/Sell signals, or experiment with different `maxFactor` values for volatility.
**Limitations**:
- Bands are reactive, as they’re based on a moving average, so confirm signals with other indicators.
- High `numLines` values may clutter the chart; use 2–4 for clarity.
- Signals may lag in fast-moving markets due to the MA’s smoothing effect.
This indicator is perfect for traders seeking a customizable, visually clear tool to enhance technical analysis on TradingView. For support, feature requests (e.g., alerts, custom colors), or community discussion, visit TradingView’s forums or contact the script author.
Bar Index ⇄ TimeLibrary to convert a bar index to a timestamp and vice versa.
Utilizes runtime memory to store the 𝚝𝚒𝚖𝚎 and 𝚝𝚒𝚖𝚎_𝚌𝚕𝚘𝚜𝚎 values of every bar on the chart (and optional future bars), with the ability of storing additional custom values for every chart bar.
█ PREFACE
This library aims to tackle some problems that pine coders (from beginners to advanced) often come across, such as:
I'm trying to draw an object with a 𝚋𝚊𝚛_𝚒𝚗𝚍𝚎𝚡 that is more than 10,000 bars into the past, but this causes my script to fail. How can I convert the 𝚋𝚊𝚛_𝚒𝚗𝚍𝚎𝚡 to a UNIX time so that I can draw visuals using xloc.bar_time ?
I have a diagonal line drawing and I want to get the "y" value at a specific time, but line.get_price() only accepts a bar index value. How can I convert the timestamp into a bar index value so that I can still use this function?
I want to get a previous 𝚘𝚙𝚎𝚗 value that occurred at a specific timestamp. How can I convert the timestamp into a historical offset so that I can use 𝚘𝚙𝚎𝚗 ?
I want to reference a very old value for a variable. How can I access a previous value that is older than the maximum historical buffer size of 𝚟𝚊𝚛𝚒𝚊𝚋𝚕𝚎 ?
This library can solve the above problems (and many more) with the addition of a few lines of code, rather than requiring the coder to refactor their script to accommodate the limitations.
█ OVERVIEW
The core functionality provided is conversion between xloc.bar_index and xloc.bar_time values.
The main component of the library is the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object, created via the 𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() function which basically stores the 𝚝𝚒𝚖𝚎 and 𝚝𝚒𝚖𝚎_𝚌𝚕𝚘𝚜𝚎 of every bar on the chart, and there are 3 more overloads to this function that allow collecting and storing additional data. Once a 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object is created, use any of the exported methods:
Methods to convert a UNIX timestamp into a bar index or bar offset:
𝚝𝚒𝚖𝚎𝚜𝚝𝚊𝚖𝚙𝚃𝚘𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡(), 𝚐𝚎𝚝𝙽𝚞𝚖𝚋𝚎𝚛𝙾𝚏𝙱𝚊𝚛𝚜𝙱𝚊𝚌𝚔()
Methods to retrieve the stored data for a bar index:
𝚝𝚒𝚖𝚎𝙰𝚝𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡(), 𝚝𝚒𝚖𝚎𝙲𝚕𝚘𝚜𝚎𝙰𝚝𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡(), 𝚟𝚊𝚕𝚞𝚎𝙰𝚝𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡(), 𝚐𝚎𝚝𝙰𝚕𝚕𝚅𝚊𝚛𝚒𝚊𝚋𝚕𝚎𝚜𝙰𝚝𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡()
Methods to retrieve the stored data at a number of bars back (i.e., historical offset):
𝚝𝚒𝚖𝚎(), 𝚝𝚒𝚖𝚎𝙲𝚕𝚘𝚜𝚎(), 𝚟𝚊𝚕𝚞𝚎()
Methods to retrieve all the data points from the earliest bar (or latest bar) stored in memory, which can be useful for debugging purposes:
𝚐𝚎𝚝𝙴𝚊𝚛𝚕𝚒𝚎𝚜𝚝𝚂𝚝𝚘𝚛𝚎𝚍𝙳𝚊𝚝𝚊(), 𝚐𝚎𝚝𝙻𝚊𝚝𝚎𝚜𝚝𝚂𝚝𝚘𝚛𝚎𝚍𝙳𝚊𝚝𝚊()
Note: the library's strong suit is referencing data from very old bars in the past, which is especially useful for scripts that perform its necessary calculations only on the last bar.
█ USAGE
Step 1
Import the library. Replace with the latest available version number for this library.
//@version=6
indicator("Usage")
import n00btraders/ChartData/
Step 2
Create a 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object to collect data on every bar. Do not declare as `var` or `varip`.
chartData = ChartData.collectChartData() // call on every bar to accumulate the necessary data
Step 3
Call any method(s) on the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object. Do not modify its fields directly.
if barstate.islast
int firstBarTime = chartData.timeAtBarIndex(0)
int lastBarTime = chartData.time(0)
log.info("First `time`: " + str.format_time(firstBarTime) + ", Last `time`: " + str.format_time(lastBarTime))
█ EXAMPLES
• Collect Future Times
The overloaded 𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() functions that accept a 𝚋𝚊𝚛𝚜𝙵𝚘𝚛𝚠𝚊𝚛𝚍 argument can additionally store time values for up to 500 bars into the future.
//@version=6
indicator("Example `collectChartData(barsForward)`")
import n00btraders/ChartData/1
chartData = ChartData.collectChartData(barsForward = 500)
var rectangle = box.new(na, na, na, na, xloc = xloc.bar_time, force_overlay = true)
if barstate.islast
int futureTime = chartData.timeAtBarIndex(bar_index + 100)
int lastBarTime = time
box.set_lefttop(rectangle, lastBarTime, open)
box.set_rightbottom(rectangle, futureTime, close)
box.set_text(rectangle, "Extending box 100 bars to the right. Time: " + str.format_time(futureTime))
• Collect Custom Data
The overloaded 𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() functions that accept a 𝚟𝚊𝚛𝚒𝚊𝚋𝚕𝚎𝚜 argument can additionally store custom user-specified values for every bar on the chart.
//@version=6
indicator("Example `collectChartData(variables)`")
import n00btraders/ChartData/1
var map variables = map.new()
variables.put("open", open)
variables.put("close", close)
variables.put("open-close midpoint", (open + close) / 2)
variables.put("boolean", open > close ? 1 : 0)
chartData = ChartData.collectChartData(variables = variables)
var fgColor = chart.fg_color
var table1 = table.new(position.top_right, 2, 9, color(na), fgColor, 1, fgColor, 1, true)
var table2 = table.new(position.bottom_right, 2, 9, color(na), fgColor, 1, fgColor, 1, true)
if barstate.isfirst
table.cell(table1, 0, 0, "ChartData.value()", text_color = fgColor)
table.cell(table2, 0, 0, "open ", text_color = fgColor)
table.merge_cells(table1, 0, 0, 1, 0)
table.merge_cells(table2, 0, 0, 1, 0)
for i = 1 to 8
table.cell(table1, 0, i, text_color = fgColor, text_halign = text.align_left, text_font_family = font.family_monospace)
table.cell(table2, 0, i, text_color = fgColor, text_halign = text.align_left, text_font_family = font.family_monospace)
table.cell(table1, 1, i, text_color = fgColor)
table.cell(table2, 1, i, text_color = fgColor)
if barstate.islast
for i = 1 to 8
float open1 = chartData.value("open", 5000 * i)
float open2 = i < 3 ? open : -1
table.cell_set_text(table1, 0, i, "chartData.value(\"open\", " + str.tostring(5000 * i) + "): ")
table.cell_set_text(table2, 0, i, "open : ")
table.cell_set_text(table1, 1, i, str.tostring(open1))
table.cell_set_text(table2, 1, i, open2 >= 0 ? str.tostring(open2) : "Error")
• xloc.bar_index → xloc.bar_time
The 𝚝𝚒𝚖𝚎 value (or 𝚝𝚒𝚖𝚎_𝚌𝚕𝚘𝚜𝚎 value) can be retrieved for any bar index that is stored in memory by the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object.
//@version=6
indicator("Example `timeAtBarIndex()`")
import n00btraders/ChartData/1
chartData = ChartData.collectChartData()
if barstate.islast
int start = bar_index - 15000
int end = bar_index - 100
// line.new(start, close, end, close) // !ERROR - `start` value is too far from current bar index
start := chartData.timeAtBarIndex(start)
end := chartData.timeAtBarIndex(end)
line.new(start, close, end, close, xloc.bar_time, width = 10)
• xloc.bar_time → xloc.bar_index
Use 𝚝𝚒𝚖𝚎𝚜𝚝𝚊𝚖𝚙𝚃𝚘𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡() to find the bar that a timestamp belongs to.
If the timestamp falls in between the close of one bar and the open of the next bar,
the 𝚜𝚗𝚊𝚙 parameter can be used to determine which bar to choose:
𝚂𝚗𝚊𝚙.𝙻𝙴𝙵𝚃 - prefer to choose the leftmost bar (typically used for closing times)
𝚂𝚗𝚊𝚙.𝚁𝙸𝙶𝙷𝚃 - prefer to choose the rightmost bar (typically used for opening times)
𝚂𝚗𝚊𝚙.𝙳𝙴𝙵𝙰𝚄𝙻𝚃 (or 𝚗𝚊) - copies the same behavior as xloc.bar_time uses for drawing objects
//@version=6
indicator("Example `timestampToBarIndex()`")
import n00btraders/ChartData/1
startTimeInput = input.time(timestamp("01 Aug 2025 08:30 -0500"), "Session Start Time")
endTimeInput = input.time(timestamp("01 Aug 2025 15:15 -0500"), "Session End Time")
chartData = ChartData.collectChartData()
if barstate.islastconfirmedhistory
int startBarIndex = chartData.timestampToBarIndex(startTimeInput, ChartData.Snap.RIGHT)
int endBarIndex = chartData.timestampToBarIndex(endTimeInput, ChartData.Snap.LEFT)
line1 = line.new(startBarIndex, 0, startBarIndex, 1, extend = extend.both, color = color.new(color.green, 60), force_overlay = true)
line2 = line.new(endBarIndex, 0, endBarIndex, 1, extend = extend.both, color = color.new(color.green, 60), force_overlay = true)
linefill.new(line1, line2, color.new(color.green, 90))
// using Snap.DEFAULT to show that it is equivalent to drawing lines using `xloc.bar_time` (i.e., it aligns to the same bars)
startBarIndex := chartData.timestampToBarIndex(startTimeInput)
endBarIndex := chartData.timestampToBarIndex(endTimeInput)
line.new(startBarIndex, 0, startBarIndex, 1, extend = extend.both, color = color.yellow, width = 3)
line.new(endBarIndex, 0, endBarIndex, 1, extend = extend.both, color = color.yellow, width = 3)
line.new(startTimeInput, 0, startTimeInput, 1, xloc.bar_time, extend.both, color.new(color.blue, 85), width = 11)
line.new(endTimeInput, 0, endTimeInput, 1, xloc.bar_time, extend.both, color.new(color.blue, 85), width = 11)
• Get Price of Line at Timestamp
The pine script built-in function line.get_price() requires working with bar index values. To get the price of a line in terms of a timestamp, convert the timestamp into a bar index or offset.
//@version=6
indicator("Example `line.get_price()` at timestamp")
import n00btraders/ChartData/1
lineStartInput = input.time(timestamp("01 Aug 2025 08:30 -0500"), "Line Start")
chartData = ChartData.collectChartData()
var diagonal = line.new(na, na, na, na, force_overlay = true)
if time <= lineStartInput
line.set_xy1(diagonal, bar_index, open)
if barstate.islastconfirmedhistory
line.set_xy2(diagonal, bar_index, close)
if barstate.islast
int timeOneWeekAgo = timenow - (7 * timeframe.in_seconds("1D") * 1000)
// Note: could also use `timetampToBarIndex(timeOneWeekAgo, Snap.DEFAULT)` and pass the value directly to `line.get_price()`
int barsOneWeekAgo = chartData.getNumberOfBarsBack(timeOneWeekAgo)
float price = line.get_price(diagonal, bar_index - barsOneWeekAgo)
string formatString = "Time 1 week ago: {0,number,#} - Equivalent to {1} bars ago 𝚕𝚒𝚗𝚎.𝚐𝚎𝚝_𝚙𝚛𝚒𝚌𝚎(): {2,number,#.##}"
string labelText = str.format(formatString, timeOneWeekAgo, barsOneWeekAgo, price)
label.new(timeOneWeekAgo, price, labelText, xloc.bar_time, style = label.style_label_lower_right, size = 16, textalign = text.align_left, force_overlay = true)
█ RUNTIME ERROR MESSAGES
This library's functions will generate a custom runtime error message in the following cases:
𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() is not called consecutively, or is called more than once on a single bar
Invalid 𝚋𝚊𝚛𝚜𝙵𝚘𝚛𝚠𝚊𝚛𝚍 argument in the 𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() function
Invalid 𝚟𝚊𝚛𝚒𝚊𝚋𝚕𝚎𝚜 argument in the 𝚌𝚘𝚕𝚕𝚎𝚌𝚝𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊() function
Invalid 𝚕𝚎𝚗𝚐𝚝𝚑 argument in any of the functions that accept a number of bars back
Note: there is no runtime error generated for an invalid 𝚝𝚒𝚖𝚎𝚜𝚝𝚊𝚖𝚙 or 𝚋𝚊𝚛𝙸𝚗𝚍𝚎𝚡 argument in any of the functions. Instead, the functions will assign 𝚗𝚊 to the returned values.
Any other runtime errors are due to incorrect usage of the library.
█ NOTES
• Function Descriptions
The library source code uses Markdown for the exported functions. Hover over a function/method call in the Pine Editor to display formatted, detailed information about the function/method.
//@version=6
indicator("Demo Function Tooltip")
import n00btraders/ChartData/1
chartData = ChartData.collectChartData()
int barIndex = chartData.timestampToBarIndex(timenow)
log.info(str.tostring(barIndex))
• Historical vs. Realtime Behavior
Under the hood, the data collector for this library is declared as `var`. Because of this, the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object will always reflect the latest available data on realtime updates. Any data that is recorded for historical bars will remain unchanged throughout the execution of a script.
//@version=6
indicator("Demo Realtime Behavior")
import n00btraders/ChartData/1
var map variables = map.new()
variables.put("open", open)
variables.put("close", close)
chartData = ChartData.collectChartData(variables)
if barstate.isrealtime
varip float initialOpen = open
varip float initialClose = close
varip int updateCount = 0
updateCount += 1
float latestOpen = open
float latestClose = close
float recordedOpen = chartData.valueAtBarIndex("open", bar_index)
float recordedClose = chartData.valueAtBarIndex("close", bar_index)
string formatString = "# of updates: {0} 𝚘𝚙𝚎𝚗 at update #1: {1,number,#.##} 𝚌𝚕𝚘𝚜𝚎 at update #1: {2,number,#.##} "
+ "𝚘𝚙𝚎𝚗 at update #{0}: {3,number,#.##} 𝚌𝚕𝚘𝚜𝚎 at update #{0}: {4,number,#.##} "
+ "𝚘𝚙𝚎𝚗 stored in memory: {5,number,#.##} 𝚌𝚕𝚘𝚜𝚎 stored in memory: {6,number,#.##}"
string labelText = str.format(formatString, updateCount, initialOpen, initialClose, latestOpen, latestClose, recordedOpen, recordedClose)
label.new(bar_index, close, labelText, style = label.style_label_left, force_overlay = true)
• Collecting Chart Data for Other Contexts
If your use case requires collecting chart data from another context, avoid directly retrieving the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 object as this may exceed memory limits .
//@version=6
indicator("Demo Return Calculated Results")
import n00btraders/ChartData/1
timeInput = input.time(timestamp("01 Sep 2025 08:30 -0500"), "Time")
var int oneMinuteBarsAgo = na
// !ERROR - Memory Limits Exceeded
// chartDataArray = request.security_lower_tf(syminfo.tickerid, "1", ChartData.collectChartData())
// oneMinuteBarsAgo := chartDataArray.last().getNumberOfBarsBack(timeInput)
// function that returns calculated results (a single integer value instead of an entire `ChartData` object)
getNumberOfBarsBack() =>
chartData = ChartData.collectChartData()
chartData.getNumberOfBarsBack(timeInput)
calculatedResultsArray = request.security_lower_tf(syminfo.tickerid, "1", getNumberOfBarsBack())
oneMinuteBarsAgo := calculatedResultsArray.size() > 0 ? calculatedResultsArray.last() : na
if barstate.islast
string labelText = str.format("The selected timestamp occurs 1-minute bars ago", oneMinuteBarsAgo)
label.new(bar_index, hl2, labelText, style = label.style_label_left, size = 16, force_overlay = true)
• Memory Usage
The library's convenience and ease of use comes at the cost of increased usage of computational resources. For simple scripts, using this library will likely not cause any issues with exceeding memory limits. But for large and complex scripts, you can reduce memory issues by specifying a lower 𝚌𝚊𝚕𝚌_𝚋𝚊𝚛𝚜_𝚌𝚘𝚞𝚗𝚝 amount in the indicator() or strategy() declaration statement.
//@version=6
// !ERROR - Memory Limits Exceeded using the default number of bars available (~20,000 bars for Premium plans)
//indicator("Demo `calc_bars_count` parameter")
// Reduce number of bars using `calc_bars_count` parameter
indicator("Demo `calc_bars_count` parameter", calc_bars_count = 15000)
import n00btraders/ChartData/1
map variables = map.new()
variables.put("open", open)
variables.put("close", close)
variables.put("weekofyear", weekofyear)
variables.put("dayofmonth", dayofmonth)
variables.put("hour", hour)
variables.put("minute", minute)
variables.put("second", second)
// simulate large memory usage
chartData0 = ChartData.collectChartData(variables)
chartData1 = ChartData.collectChartData(variables)
chartData2 = ChartData.collectChartData(variables)
chartData3 = ChartData.collectChartData(variables)
chartData4 = ChartData.collectChartData(variables)
chartData5 = ChartData.collectChartData(variables)
chartData6 = ChartData.collectChartData(variables)
chartData7 = ChartData.collectChartData(variables)
chartData8 = ChartData.collectChartData(variables)
chartData9 = ChartData.collectChartData(variables)
log.info(str.tostring(chartData0.time(0)))
log.info(str.tostring(chartData1.time(0)))
log.info(str.tostring(chartData2.time(0)))
log.info(str.tostring(chartData3.time(0)))
log.info(str.tostring(chartData4.time(0)))
log.info(str.tostring(chartData5.time(0)))
log.info(str.tostring(chartData6.time(0)))
log.info(str.tostring(chartData7.time(0)))
log.info(str.tostring(chartData8.time(0)))
log.info(str.tostring(chartData9.time(0)))
if barstate.islast
result = table.new(position.middle_right, 1, 1, force_overlay = true)
table.cell(result, 0, 0, "Script Execution Successful ✅", text_size = 40)
█ EXPORTED ENUMS
Snap
Behavior for determining the bar that a timestamp belongs to.
Fields:
LEFT : Snap to the leftmost bar.
RIGHT : Snap to the rightmost bar.
DEFAULT : Default `xloc.bar_time` behavior.
Note: this enum is used for the 𝚜𝚗𝚊𝚙 parameter of 𝚝𝚒𝚖𝚎𝚜𝚝𝚊𝚖𝚙𝚃𝚘𝙱𝚊𝚛𝙸𝚗𝚍𝚎𝚡().
█ EXPORTED TYPES
Note: users of the library do not need to worry about directly accessing the fields of these types; all computations are done through method calls on an object of the 𝙲𝚑𝚊𝚛𝚝𝙳𝚊𝚝𝚊 type.
Variable
Represents a user-specified variable that can be tracked on every chart bar.
Fields:
name (series string) : Unique identifier for the variable.
values (array) : The array of stored values (one value per chart bar).
ChartData
Represents data for all bars on a chart.
Fields:
bars (series int) : Current number of bars on the chart.
timeValues (array) : The `time` values of all chart (and future) bars.
timeCloseValues (array) : The `time_close` values of all chart (and future) bars.
variables (array) : Additional custom values to track on all chart bars.
█ EXPORTED FUNCTIONS
collectChartData()
Collects and tracks the `time` and `time_close` value of every bar on the chart.
Returns: `ChartData` object to convert between `xloc.bar_index` and `xloc.bar_time`.
collectChartData(barsForward)
Collects and tracks the `time` and `time_close` value of every bar on the chart as well as a specified number of future bars.
Parameters:
barsForward (simple int) : Number of future bars to collect data for.
Returns: `ChartData` object to convert between `xloc.bar_index` and `xloc.bar_time`.
collectChartData(variables)
Collects and tracks the `time` and `time_close` value of every bar on the chart. Additionally, tracks a custom set of variables for every chart bar.
Parameters:
variables (simple map) : Custom values to collect on every chart bar.
Returns: `ChartData` object to convert between `xloc.bar_index` and `xloc.bar_time`.
collectChartData(barsForward, variables)
Collects and tracks the `time` and `time_close` value of every bar on the chart as well as a specified number of future bars. Additionally, tracks a custom set of variables for every chart bar.
Parameters:
barsForward (simple int) : Number of future bars to collect data for.
variables (simple map) : Custom values to collect on every chart bar.
Returns: `ChartData` object to convert between `xloc.bar_index` and `xloc.bar_time`.
█ EXPORTED METHODS
method timestampToBarIndex(chartData, timestamp, snap)
Converts a UNIX timestamp to a bar index.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
timestamp (series int) : A UNIX time.
snap (series Snap) : A `Snap` enum value.
Returns: A bar index, or `na` if unable to find the appropriate bar index.
method getNumberOfBarsBack(chartData, timestamp)
Converts a UNIX timestamp to a history-referencing length (i.e., number of bars back).
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
timestamp (series int) : A UNIX time.
Returns: A bar offset, or `na` if unable to find a valid number of bars back.
method timeAtBarIndex(chartData, barIndex)
Retrieves the `time` value for the specified bar index.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
barIndex (int) : The bar index.
Returns: The `time` value, or `na` if there is no `time` stored for the bar index.
method time(chartData, length)
Retrieves the `time` value of the bar that is `length` bars back relative to the latest bar.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
length (series int) : Number of bars back.
Returns: The `time` value `length` bars ago, or `na` if there is no `time` stored for that bar.
method timeCloseAtBarIndex(chartData, barIndex)
Retrieves the `time_close` value for the specified bar index.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
barIndex (series int) : The bar index.
Returns: The `time_close` value, or `na` if there is no `time_close` stored for the bar index.
method timeClose(chartData, length)
Retrieves the `time_close` value of the bar that is `length` bars back from the latest bar.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
length (series int) : Number of bars back.
Returns: The `time_close` value `length` bars ago, or `na` if there is none stored.
method valueAtBarIndex(chartData, name, barIndex)
Retrieves the value of a custom variable for the specified bar index.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
name (series string) : The variable name.
barIndex (series int) : The bar index.
Returns: The value of the variable, or `na` if that variable is not stored for the bar index.
method value(chartData, name, length)
Retrieves a variable value of the bar that is `length` bars back relative to the latest bar.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
name (series string) : The variable name.
length (series int) : Number of bars back.
Returns: The value `length` bars ago, or `na` if that variable is not stored for the bar index.
method getAllVariablesAtBarIndex(chartData, barIndex)
Retrieves all custom variables for the specified bar index.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
barIndex (series int) : The bar index.
Returns: Map of all custom variables that are stored for the specified bar index.
method getEarliestStoredData(chartData)
Gets all values from the earliest bar data that is currently stored in memory.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
Returns: A tuple:
method getLatestStoredData(chartData, futureData)
Gets all values from the latest bar data that is currently stored in memory.
Namespace types: ChartData
Parameters:
chartData (series ChartData) : The `ChartData` object.
futureData (series bool) : Whether to include the future data that is stored in memory.
Returns: A tuple:
Dynamic EMA Cloud📘 Dynamic EMA Cloud – Quick Guide
What it does:
- Shades the area between two EMAs (default 8 & 21).
- Cloud flips green when the fast EMA is on top (bullish), red when it’s underneath (bearish).
- The cloud gets thicker in strong trends and thinner when things are weak or choppy.
- Top-right box shows the EMA trend and which sizing mode you’re using.
Cloud Width Modes:
- EMA Gap → Cloud follows the distance between the EMAs. Great for spotting trend strength.
- ATR → Uses volatility. Wide in high-vol markets, tight in low-vol.
- Percent → Fixed % of price. Keeps charts looking consistent whether it’s a $2 penny stock or a $2000 ticker.
- Hybrid → Mix of both EMA gap and ATR. A “best of both” setting.
How to read it:
- Price riding above a green cloud = bullish control.
- Price staying under a red cloud = bearish control.
- A skinny cloud = trend might be running out of gas or a reversal coming.
- A fat cloud = momentum is strong, trend is solid.
Tips:
- For scalping/day trading, use faster EMAs (like 8 & 21).
- For swing trades, use slower pairs (20 & 50, 50 & 200).
- The floating label tells you “Bullish / Bearish / Neutral” at the current bar.
- Corner tag keeps you oriented no matter where you scroll.
Let me know what you think!
SniperKills-Session Sweeps + SMT📊 Session Sweeps + SMT Tracker
🌏 Asia Session (8PM–12AM NY) → candles 🔴 red
🇬🇧 London Session (2AM–5AM NY) → candles 🟠 orange
✅ Sweep Hit – shows if a sweep occurred during the session
📈 High / Low – tracks session extremes dynamically
🔄 SMT Detection – flags bullish ✅ or bearish ❌ divergences vs correlated instrument
📋 Live Table – updates at top-right of chart for quick reference
Perfect for NQ intraday trading, teaching, or monitoring session activity visually.
cd_Quarterly_cycles_SSMT_TPD_CxGeneral
This indicator is designed in line with the Quarterly Theory to display each cycle on the chart, either boxed and/or in candlestick form.
Additionally, it performs inter-cycle divergence analysis ( SSMT ) with the correlated symbol, Terminus Price Divergence ( TPD ), Precision Swing Point ( PSP ) analysis, and potential Power of Three ( PO3 ) analysis.
Special thanks to @HandlesHandled for his great indicator, which I used while preparing the cycles content.
Details & Usage:
Optional cycles available: Weekly, Daily, 90m, and Micro cycles.
Displaying/removing cycles can be controlled from the menu (cycles / candles / labels).
All selected cycles can be shown, or you can limit the number of displayed cycles (min: 2, max: 4).
The summary table can be toggled on/off and repositioned.
What’s in the summary table?
• Below the header, the correlated symbol used in the analysis is displayed (e.g., SSMT → US500).
• If available, live and previous bar results of the SSMT analysis are shown.
• Under the PSP & TPD section, results are displayed when conditions are met.
• Under Alerts, the real-time status of conditions defined in the menu is shown.
• Under Potential AMD, possible PO3 analysis results are displayed.
Analysis & Symbol Selection:
To run analyses, a correlated symbol must first be defined with the main symbol.
Default pairs are preloaded (see below), but users should adjust them according to their exchange and instruments.
If no correlated pair is defined, cycles are displayed only as boxes/candles.
Once defined pairs are opened on the chart, analyses load automatically.
Pairs listed on the same row in the menu are automatically linked, so no need to re-enter them across rows.
SSMT Analysis:
Based on the chart’s timeframe, divergences are searched across Weekly, Daily, 90m, and Micro cycles.
The code will not produce results for smaller cycles than the current timeframe.
(Example: On H1, Micro cycles will not be displayed.)
Results are obtained by comparing the highs and lows of consecutive cycles in the same period.
If one pair makes a new high/low while the other does not, this divergence is added to SSMT results.
The difference from classic SMT is that cycles are used instead of bars.
PSP & TPD Analysis:
A correlated symbol must be defined.
For PSP, timeframe options are added to the menu.
Users toggle timeframes on/off by checking/unchecking boxes.
In selected timeframes, PSP & TPD analysis is performed.
• PSP: If candlesticks differ in color (bullish/bearish) between symbols and the bar is at a high/low of the timeframe (and higher/lower than the bars before/after it), it is identified as a PSP. Divergences between pairs are interpreted as potential reversal signals.
• TPD: Once a PSP occurs, the closing price of the previous bar and the opening price of the next bar are compared. If one symbol shows continuation while the other does not, it is marked as a divergence.
Example:
Let’s assume Pair 1 and Pair 2 are selected in the menu with the H4 timeframe, and our cycle is Weekly (Box).
For Pair 1, the H4 candle at the Weekly high level:
• Is positioned at the Weekly high,
• Its high is above both the previous and the next candle,
• It closed bearish (open > close).
For Pair 2, the same H4 candle closed bullish (close > open).
→ PSP conditions are met.
For TPD, we now check the candles before and after this PSP (H4) candle on both pairs.
Comparing the previous candle’s close with the next candle’s open, we see that:
• In Pair 1, the next open is lower than the previous close,
• In Pair 2, the next open is higher than the previous close.
Pair 1 → close > open
Pair 2 → close < open
Since they are not aligned in the same direction, this is interpreted as a divergence — a potential reversal signal.
While TPD results are displayed in the summary table, whenever the conditions are met in the selected timeframes, the signals are also plotted directly on the chart. (🚦, X)
• Higher timeframe TPD example:
• Current timeframe TPD example:
Alerts:
The indicator can be conditioned based on aligned timeframes defined within the concept.
Example (assuming random active rows in the screenshot):
• Weekly Bullish SSMT → Tf2 (menu-selected) Bullish TPD → Daily Bullish SSMT.
Selecting “none” in the menu means that condition is not required.
When an alert is triggered, it will be displayed in the corresponding row of the table.
• Example with only condition 3 enabled:
Potential PO3 Analysis:
According to Quarterly Theory, price moves in cycles, and the same structures are assumed to continue in smaller timeframes.
From classical PO3 knowledge: before the main move, price first manipulates in the opposite direction to trap buyers/sellers, then makes its true move.
The cyclical sequence is:
(A)ccumulation → (M)anipulation → (D)istribution → (R)eversal / Continuation.
Within cycle candles, the first letter of each phase is displayed.
So how does the analysis work?
If the active cycle is in (M)anipulation or (D)istribution phase, and it sweeps the previous cycle’s high or low but then pulls back inside, this is flagged in the summary table as a possible PO3 signal.
In other words, it reflects the alignment of theoretical sequence with real-time price action.
Confluence with SSMT and TPD conditions further strengthens the expectation.
Final Note:
No single marking or alert carries meaning on its own — it must always be evaluated in the context of your concept knowledge.
Instead of trading purely on expectations, align bias + trend + entry confirmations to improve your success rate.
Feedback and suggestions are welcome.
Happy trading!
Scalper Plot Bored YetiThe Scalper Plot Bored Yeti indicator automatically calculates a custom session range (High & Low) and plots additional scalp and stop-loss levels in ticks.
Session Range (H/L): Define any custom intraday window (e.g., 08:30–09:30) to calculate the range.
Scalp Levels: Plot take-profit extensions above the High and below the Low, measured in ticks.
Scalper SL Levels: Plot stop-loss offsets inside the range (High − ticks, Low + ticks).
Offsets: Apply custom tick offsets to the base High/Low before level calculations.
Labels & Styling: Fully configurable label text, size, colors, line styles, and extension options.
Display Control: Option to keep all levels on the chart or show only the most recent session.
Impatience Blocker — Large TextWhat it is:
A simple on-chart “lock screen” for TradingView that throws a giant white panel over your candles with a big message:
“IS THERE ANY PLAYS OR ARE YOU JUST IMPATIENT?”
It’s a behavioral guardrail to stop revenge trades and force you to wait for clean setups.
How it works (under the hood):
Draws a full-pane white box using time-based coordinates so it always covers the visible chart.
Renders the phrase in large, bold-looking text (stacked labels for thickness).
Updates every bar so the message stays centered as you scroll/zoom.
Toggle on/off via a single input: “Show Blocker (ON hides chart)”.
Why use it:
Break the “must click something” reflex during chop.
Reset your bias and wait for A+ signals.
Great for students/mentees who need a visual stop sign.
Inputs:
Show Blocker (ON hides chart): true/false toggle.
Notes / Limits:
It does not block broker buttons (TradingView doesn’t allow that). It’s a visual deterrent.
Pair it with your risk rules or a Discord “Lock Out” button on your execution bot for real enforcement.
Customize:
Change the message text in txt = "...".
Change text color by replacing textcolor=color.black (e.g., color.red).
If your chart background is white, keep the panel white or set a light gray: color.rgb(245,245,245).
Best practice:
Map the toggle to your Favorites so it’s one click to “go dark.”
Use it during no-trade windows (post-entry cooldowns, news minutes, end-of-day chop).
ATR(14) 5m + 15m — SL% • ATR (panel compacto)Indicator that shows what percentage to set for your SL according to your strategy and trading style, based on volatility.
4H Range Breakout Strategy — ETH 4H optimized 4H Range Breakout Strategy — with Regime Auto-Tuning, Fixed-Risk Sizing & Forward Plan (no-repaint)
What it is
A rules-based breakout strategy that trades the confirmed prior 4H range (no repaint), then adapts to market regime (Trend / Range / High-Vol) and sizes positions by fixed account risk. It includes a forward plan (projected SL/TP levels), a scenario engine (Breakout / Retest / Failed-breakout paths), and optional Pro signals that require volume/RSI confirmation.
Why this is original/useful
All components are designed to work together around a single idea: only trade when price closes beyond the prior 4H range and the market conditions justify it. Filters (EMA200/ADX, volatility, volume) gate entries; risk is standardized in % of equity; exits combine TP1 scale-out + dynamic BE + ATR chandelier. The scenario/forward tools help users plan trades without repainting.
How it works (logic)
Higher-TF range: We fetch previous 4H High/Low (confirmed, lookahead_off).
Breakout triggers:
– Long when close > (4H High + buffer).
– Short when close < (4H Low − buffer).
Filters:
– Trend: Daily EMA200 and/or ADX with a minimum threshold.
– Volatility/Volume: ATR>SMA(ATR) and Volume>SMA(Vol).
– Optional RSI guard (avoid OB/OS extremes).
Stops/Targets:
– Initial stop = ATR-based (or %).
– TP Final = ATR multiple or R multiple (user-selectable).
– TP1 scale-out moves the rest to breakeven, then trails via ATR chandelier.
Cool-down: Blocks immediate re-entries for N bars.
Fixed-risk sizing: Each trade risks a fixed % of equity (default 0.5%), respecting min/step and a max exposure cap.
Kill-Switch (prop-style): Stops new entries after a daily loss limit or a losing streak; resets per rules.
Regime Auto-Tune: Uses ADX, EMA200 Daily slope and ATR z-score to tighten/loosen buffers, targets and trailing in Trend / Range / High-Vol regimes.
Forward Plan & Scenarios: Projects next SL/TP lines and labels; draws primary path (Breakout/Retest/Failed) towards nearest HTF S/R (from pivots) for planning only (no orders).
No-repaint policy: All signals use bar closes and request.security(..., lookahead_off). No future-bar data, no repainting.
Default Properties & Backtest Settings
Symbol/TF: Works on crypto majors; authors’ defaults typically H1 / M15 / 4H profiles.
Initial capital: 10,000.
Commission: 0.04% per side (adjust to your venue).
Slippage: 2 ticks (adjust to symbol tick size/liquidity).
Position sizing: Fixed-risk = 0.5% of equity per trade (≤1% recommended).
Pyramiding: 0.
Sample size: Use a dataset large enough to obtain >100 trades before drawing conclusions (e.g., 1–3 years on BTC/ETH M15/H1).
These defaults are intentionally conservative and should be kept when publishing.
How to use
Choose a TF profile (M15/H1/4H) and keep the default risk.
Make sure Commission/Slippage match your market.
Use the Forward Plan / Scenario labels to plan entries around the breakout; the lines are projections (not signals).
Optionally toggle Pro signals to see stricter, volume-supported entries (visual only).
Review the Kill-Switch and cool-down if you’re prop-testing.
Limitations & notes
Not financial advice. Trend/range detection and S/R from pivots are heuristic and can fail in chop or news.
Do not over-optimize parameters on a single symbol/TF; validate on out-of-sample data.
The “Pro signals” are markers only; orders are placed by the core breakout logic.
Credits
Pine built-ins (RSI/ADX/ATR), EMA200. All other logic, regime control, fixed-risk sizing, kill-switch and forward/scenario modules implemented by the author for this strategy.
Changelog: v1.0 – initial public release with regime auto-tune, fixed-risk sizing, forward plan & Pro markers.
Session BreaksSession Breaks (stable) draws vertical lines at the exact start of each Day / Week / Month / Quarter / Half-Year / Year aligned to the instrument’s TradingView session (Regular, Extended, or Custom). The script prioritizes higher timeframes (Y→H→Q→M→W→D) so lines never overlap, and it works on any chart timeframe.
Features
Session-aligned boundaries (respect exchange hours)
Toggle any timeframe, pick colors/styles
“Highest TF wins” de-dup logic (no clutter)
Lightweight, history-safe (line cap to protect performance)
Indicator only — places no orders or alerts by itself
Tip: Choose the session mode in settings to match your market hours.
GSR-MINI BandsGSR-Mini Bands is an indicator designed to analyze the dynamics of implied volatility indices, such as the VIX (S&P500) or the VDAX-NEW (DAX40).
The calculation is performed as the percentage difference between the cumulative series of opening gaps and the cumulative evolution of the volatility index itself, adjusted for those gaps.
The indicator moves in a range of approximately -1 to 1, with intermediate lines (0.3 and 0.7) that help identify different relative levels of volatility behavior.
Although it is primarily designed for daily charts, it can also be applied to shorter time frames, such as 1 minute, where it offers additional insight into intraday volatility dynamics.
Note : This indicator does not constitute an investment recommendation. It is presented solely as a technical analysis tool.
Dynamic EMA x VWAP Alerts Dynamic EMA × VWAP Alerts finds EMA crossover entries only when price sits in a meaningful VWAP context. It supports Daily, Weekly, and Rolling VWAP anchors with ±1/2/3σ bands, so signals are filtered by where price is relative to VWAP/bands instead of firing everywhere. Optional ATR, Relative-Volume, and Distance guards further trim noise. Time Windows let you keep the tool active only during the parts of the day you actually trade (with a timezone selector to match the market).
Case example
Swing trading - pre-filtering:
Swing trading - post-filtering:
How it works
• Signals: BUY when fast EMA crosses above slow EMA; SELL on the opposite — evaluated once per bar close (non-repainting).
• Gates: choose BUY/SELL levels (VWAP, ±1σ/±2σ/±3σ) and the source (Daily, Weekly, or Rolling). Gate modes Single / AND (Both) / OR (Either) control how sources combine.
• Filters (optional): ATR (% or regime), Relative Volume, and Distance guards are OFF by default and can be turned on as needed.
• Time Windows: set an Active window plus up to 3 Blackouts relative to the VWAP window start; pick a timezone (ET / Exchange / UTC) so you don’t have to do mental offsets.
Quick start
1) Show Daily VWAP and pick Gate Mode + BUY/SELL levels.
2) Choose Double or Triple EMA and (optionally) display the lines.
3) (Optional) Enable ATR / R-Vol / Distance.
4) (Optional) Configure Time Windows and select the timezone.
5) Add alerts: use the two built-in BUY/SELL alertconditions and set them to Once-per-bar-close.
Notes
• Non-repainting by design: logic runs on bar close; no higher-TF lookahead.
• Built for multiple markets and timeframes; Rolling VWAP is O(1) per bar; the Time Windows gate applies to intraday bars by design.
Quarters HTF: 1M/3M/6M/1YQuarters HTF — 1M / 3M / 6M / 1Y
Quartered Month / 3M / 6M / Year underlay. Finish-forward boxes to the next open. Lookback modes: Unlimited / Periods / Days / Bars.
('Pin to scale' may need to be set to "no scale")
Quarters LTF: Day/Week + 5H/4HQuarters LTF — Day/Week + 5H/4H
Quartered time blocks for Day/Week plus intraday 5H×4 and last 4H×4. Finish-forward boxes to the next open. Lookback modes: Unlimited / Periods / Days / Bars.
('Pin to scale' may need to be set to "no scale")
Lau3%Lau3% is a technical analysis tool that combines:
adaptive moving averages for trend evaluation,
a dynamic volatility-based trailing line for trend following,
current-period zones for key level visualization,
signals for regime shift or trail breakout.
[058] Daily Cycles/Sessions (D Candle 18:00) or (ICT 00:00)from 18:00 to 18:00
or
from 00:00 to 00:00
days are individually customizable
shows weekends for crypto
MARS - MACD + ADX + RSI + Stochastic RSI Signals🚀 MARS – MACD + ADX + RSI + Stochastic Signals
MARS is an advanced trading indicator that merges 4 of the most powerful technical tools: MACD, ADX, RSI, and Stochastic.
This unique combination provides clear buy and sell signals, helping you to:
✔️ Spot trend reversals with higher accuracy
✔️ Filter out false signals in volatile markets
✔️ Confirm trend strength with ADX
✔️ Trade effectively on multiple timeframes (scalping, swing, intraday)
MARS is built for traders who value simplicity and effectiveness, with clean visuals and easy-to-read signals.
💡 Support this project
MARS is free to use and protected. If you want to support my work:
🔗 Sign up and trade on my recommended exchanges using these referral links:
OKX: okx.com
BingX: bingx.com
Bitunix: www.bitunix.com
☕ Or you can send a donation in crypto:
BTC/USDT (TRC20): 0x0a3e36ac34B78A324d8948623AD77d6651Da0767
Your support helps me improve MARS and develop more tools for the trading community 🚀.
TrEx Lite [ETPINVEST]TrEx Lite is a technical indicator for basic market structure analysis. Automatically identifies extremes with trend lines, builds support/resistance levels and includes Golden/Death Cross trading strategy with additional exit points.
🔶 MAIN FUNCTIONS
The indicator provides basic structural analysis:
Automatic identification of extremes
Building trend lines through extremes
Automatic support and resistance levels
Golden Cross trading strategy (EMA 50 crosses EMA 200 from below)
Death Cross strategy (EMA 50 crosses EMA 200 from above)
Additional exit points based on EMA narrowing and RSI filtering
System of 4 basic alerts for key events
🔶 STRUCTURAL ELEMENTS
Automatic connection of extremes with trend lines
Significance filtering to exclude noise
Basic levels from extremes with touch
Built-in clustering of nearby levels to reduce noise
Color differentiation: green (support) and red (resistance)
Line thickness adjustment
🔶 TRADING STRATEGY
Golden/Death Cross system:
Golden Cross - EMA 50 crosses EMA 200 from below (bullish signal)
Death Cross - EMA 50 crosses EMA 200 from above (bearish signal)
Position tracking with automatic state management
Entry points marked with triangles on the chart
Additional exit points:
Narrowing distance between EMAs after position entry
RSI filtering against trend (crossing center line 50)
Reverse EMA crossing as main exit signal
Minimum 5 candles in position to filter false exits
🔶 SETTINGS
Trend line and levels:
Enable/disable trend line display
Trend line color and thickness (1-5 pixels)
Enable/disable levels display
Support and resistance colors
Level line thickness
Trading strategy:
Enable/disable Golden/Death Cross strategy
Show additional exit points
Automatic position tracking
Alert system (4 types):
Support/resistance level touch
Level breakout with close beyond
Golden Cross (bullish signal)
Death Cross (bearish signal)
🔶 TECHNICAL SPECIFICATIONS
Extremes algorithm: Complex algorithm with fixed parameters combining 2-3 candles
Clustering: ATR-based merging of nearby levels
Trading logic: EMA crossovers with RSI confirmation
Performance: Optimized for stable operation on all timeframes
Compatibility: All TradingView markets and timeframes
Requirements: Minimum 100 bars of history
🔶 LIMITATIONS
Fixed analysis parameters (depth 100 bars)
🔶 DISCLAIMER
TrEx Lite provides basic technical information for market structure analysis. Not investment advice. Trading strategy requires additional analysis and risk management.
US market sessionsThe script creates green and red vertical lines on the bars corresponding to the openings and closings of the US market sessions with associated labels.
Custom Alert - Volume, RSI, Bollinger Bandjust a quick script to see if i can catch the bounce off the bolinger band with low rsi
SQZMOM Candle Colors [LB clone • bar paint]This script paints candles based on the Squeeze Momentum (SQZMOM) indicator values.
It works as a bar color overlay, allowing traders to visually identify momentum shifts directly on the chart.
Inspired by LazyBear's SQZMOM, this version clones the core logic but adds candle coloring for better trend confirmation.
Features:
- SQZMOM-based candle coloring
- Momentum strength visualization
- Easy-to-spot trend shifts
Useful for identifying trend continuation and reversal zones.