High Time Frame Open Close High Low LevelsGives you the OHLC levels of the weekly and daily candles as levels in whatever timeframe you're on so you can have a macro view in lower timeframes without having to switch timeframes constantly.
You may toggle the visibility of all the daily or weekly levels as well as each individual open/close/high/low.
The line styles and colors are customizable.
Cari skrip untuk "weekly"
Trend Reversal Alerts Strategy [lite]This strategy was created as experimental and after playing around with it, I was able to realize what is a good way to base your strategy on and what is not.
This one is most primitive way and you should not expect gains from it(it's best on the weekly btw).
Anyway, all my attempts to advance this strategy in the end gave me around 1%2% +Net Profit on the hourly timeframe and drastically reduced the Net Profit by 50% on the weekly, so I think it is a waste of my time, but if you feel like you have ideas to share with me, please feel free to comments below!
Simba Bitcoin MomentumMaybe the best to trade Bitcoin on 1D!
Do you want to use it?
You can get access for one week free, after that, the weekly rental costs are 0.1 BTC. When you dont pay accurate the weekly subscription, you will be removed.
Write me an email to simba_cfd@protonmail.com when you want access.
VEGAS tunnel 4hrs - 8c;55hlsimple script for the 4hrs/ weekly Vegas tunnel
weekly script is seperate
MA Study: Different Types and More [NeoButane]A study of moving averages that utilizes different tricks I've learned to optimize them. Included is Bollinger Bands, Guppy (GMMA) and Super Guppy.
The method used to make it MtF should be more precise and smoother than regular MtF methods that use the security function. For intraday timeframes, each number represents each hour, with 24 equal to 1 day. For daily, 3 is 3 day, for weekly, 4 is the 4 weekly, etc. If you're on a higher timeframe than the one selected, the length will not change.
Log-space is used to make calculations work on many cryptos. The rules for color changing Guppy is changed to make it not as choppy on MAs other than EMA. Note that length does not affect SWMA and VWAP and source does not affect VWAP.
A short summary of each moving average can be found here: medium.com
List of included MAs:
ALMA: Arnaud Legoux
Double EMA
EMA: Exponential
Hull MA
KAMA: Kaufman Adaptive
Linear Regression Curve
LSMA: Least Squares
SMA: Simple
SMMA/RMA: Smoothed/Running
SWMA: Symm. Weighted
TMA: Triangular
Triple EMA
VWMA: Volume Weighted
WMA: Weighted
ZLEMA: Zero Lag
VWAP: Vol Weighted Average
Welles Wilder MA
Buy/Sell Strategy Traderspro 21EMA/200SMA & PivotsBuy Signal: If price closes over EMA 21 and SMA 200 and over Montly and weekly pivots.
Sell Signal: If price closes below EMA 21 and SMA 200 and below Montly and weekly pivots.
Use buystops sellstops over signal bar close
For EURUSD Daily Timeframe works better. Check other pairs to see which timeframe has better profits. I apreciate your comments
Inverted Yield Curve with VIX Fear IndexUS 2 year and US 10 year comparison, inverted yield curve with VIX. I use this on a weekly chart with 2 moving averages, the 40 week (ma200 daily) and the 520 week (10 year median).
The bottom histogram is the VIX and the plot is the yield curve. When the VIX is above a certain level (you can set it in settings) and the ýield curve is close to or at inversion the background goes red.
The last seven recessions were preceded by an inverted yield curve. Here I combined the two main fear indexes, the VIX and the run for safe US treasuries (Inverted Yield Curve).
This is preset to the 2 year and 10 year US bond, weekly, and the normal VIX ticker but you can set it to whatever you like.
Published with source code for anyone to modify. Please comment below if you do so! This is the second in a series of indicators I intend to publish as a package of economic recoverty/recession symptom indicators.
Follow me for updates, next one up is commodities with dr Copper and oil!
Automatic Support, Resistance, Fibonacci LevelsThis indicator plots absolute high and low values for up to five completely adjustable time periods (in months, weeks, days, hours, minutes) and optionally calculates the Fibonacci levels on the pair of absolutes of your choice, ascending or descending, and mimics the shading available in the built-in Fib charting tools (e.g. retracement).
Here are a few screenshots of the same chart with various options selected.
3-Month, 4-Week, and 5-Day absolutes with 3-Monthly Fib plotted:
The same chart with 4-Weekly Fib:
The same chart with 5-Daily Fib:
5-Day, 12-Hour, 90-Minute absolutes with 12-Hourly Fib:
Zoomed in, on a 30-minute interval, with 90-minute Fib:
With descending ("inverted") 90-minute Fib:
I started putting this together for Vazzyb, who was looking for a way to automate plotting horizontal support and resistance levels for monthly, weekly, and daily extremes, and then I added additional features as they occurred to me. Special thanks to Paaax, who suggested I add Fib levels.
I am leaving the code open, so you may feel free to grab snippets you like and use them for your own purposes. Of particular interest may be my custom "calc_fib()" function, which accepts any series pair, as well as a Boolean indicating whether to invert, and returns an array with each of the major Fibonacci levels: .
If anyone likes this enough to feel generous, please feel free:
BTC
3KmFchJ18QvMzAJKDcFQXvyK9p1EHWQdhP
BCH
qqtrw64ptuwprk5vtj3z8qwkvh3v0jawxq7khqng7x
ETH
0x9b51361A278910Ba3945C7519C9f0FA8a77df18d
LTC
MDeWWsP7XCG2zQuZ2dYALZXQ52u2qkc8fh
P.S. If you want the time lengths to be as close to accurate as possible, don't forget to change the number of days per week when using for cryptocurrency!
Dual Timeframe SMA Ribbon CrossoverCopyright by RJ 3/2018
Should be used with lower timeframe and higher timeframe charts
First set your chart to the lower timeframe you'd like to analyze
see f.bpcdn.co
For this method, low timeframe/high suitable timeframe pairs are:
5min with 30min parent
15min with 1hr parent
30min with 4hr parent
4hr with daily parent
daily with weekly parent
weekly with monthly parent
On lower timeframe chart - Plot of 2 smas length 6, 1 Offset
If smas cross - and bar crosses the sma convergence, and full body of bar crosses SMAs - then this is a buy or sell opportunity
For confirmation - on the higher timeframe chart, check if bar is above or below the smas for that day
Auto DayWeekMonth Fib Levels R2 by JustUncleLThis indicator automatically draws up to Three Sets of Fibonacci Pivot levels based on the previous Candle period's Range (High-Low). The HLC3 is used as the default Pivotal level. Only the most Recent period Candle Levels are displayed. The longer Weekly and Monthly sets are particularly useful in finding long term Supply and Demand levels.
The three sets of selectable periods are spit into the following sets:
Daily Set (1,2,3,4,5,7,10 or 14 Days)
Weekly Set (1,2,3,4,5,10, or 13 Weeks)
Monthly Set (1,2,3,4,5,6,9 or 12 months)
Each set has the option to display Extension levels.
The Pivotal Level HLC3 and Range = (High - Low), are extracted from previous Period Candle.
FIB LEVELS Colours (same in each period set):
Yellow = Pivot and Pivot Zone (HLC3 by default)
Fuchsia = R1,S1 Levels 0.368 * Range
Lime = R2,S2 Levels 0.618 * Range
Red = R3,S3 Levels 0.786 * Range
Aqua = R4,S4 Levels 1.000 * Range
Green = R5,S5 Levels 1.236 * Range
Orange = R6,S6 Levels 1.382 * Range
Black = R7,S7 Levels 1.618 * Range
Maroon = R8,S8 Levels 2.000 * Range
Pullback Trading Tool R5-65 by JustUncleLBy request this is an updated version of the "PullBack Trading Tool": removes experimental "OCC" channel, added option to display ribbons or just single moving average lines, added alert arrows for "PB" exits, added alertcondition for TV alarm subsystem, added some extract options for Pivot points and general cleanup of code.
Description:
This project incorporates the majority of the indicators needed to analyse and trade Trends for Pullbacks, swings and reversals.
Incorporated within this tool are the following indicators:
1. Major industry (Banks) recognised important EMAs in an EMA Ribbon:
Lime = EMA5 (Optional Display)
DodgerBlue = EMA12 (Optional Display)
Red = EMA36 (Optional display)
Green = EMA89
Blue = EMA200
Black = EMA633
2. The 5 EMA (default) High/Low/Close Price Action Channel (PAC), the PAC channel display is disabled by default.
3. Optionally display Fractals and optional Fractal levels
4. Optional HH, LH, LL, HL finder.
5. Optional Buy/Sell "PB" exit Alerts with Optional 200EMA filter.
6. Coloured coded Bar high lighting based on the PAC:
blue = bar closed above PAC
red = bar closed below PAC
gray = bar closed inside PAC
7. Alert condition sent to TradingView's Alarm subsystem for PB exits.
8. Pivot points with optional labels.
9. EMA5-12 Ribbon is displayed by default.
10.EMA12-36 Ribbon is displayed by default
Set up and hints:
I am unable to provide a full description here, as Pullback Trading incorporates a full trading Methodology, there are a number of articles and books written on the subject.
Set the chart to Heikin Ashi Candles (optional).
I also add a "Sweetspot Gold R3" indicator to the chart as well to help with support and resistance finding and shows where the important "00" lines are.
First on a weekly basis say Sunday night or Monday morning, analyse the Daily and Weekly charts to establish overall trends, and support/resistant levels. Draw significant mini trend lines (2/3 TL), vertical trend lines (VTL) and S/R levels. Can use the Pivots points to guide VTL drawing and Fractals to help guide 2/3 TL drawing.
Once the trend direction and any potential major reversals highlighted, drop down to lower timeframe chart and draw appropriate mini Trend line (2/3 TL) matching the established momentum direction. Take note of potential pull backs from and of the EMAs, in particular the EMA5-12 ribbon, EMA12-36 Ribbon and the 200EMA. Can use the Pivots and/or Fractals points to guide your 2/3 TL drawing.
Set a TradingView alarm on the "PBTOOL alert", with the default settings this normally occurs before or during the Break of the manually drawn TL lines.
Once alerted check to see if the TL is broken and is returning to trend away from the EMA lines, this is indicated by bar colour change to trend directional colour.
You can trade that alert or drop down to even lower time frames and perform the same TL analysis there to find trades at the lower TF. Trading at lower TF you will allow tighter Stop loss settings.
Other than the "SweetSpot Gold R3" indicator, you should not need any other indicator to successfully trade trends for Pullbacks and reversals. If you really want another indicator I suggest a momentum one for example: AO ( Awesome Oscillator ), MACD or Squeeze Momentum.
KK_Average Directional Index (ADX) Higher TFHey guys,
sometimes you just want to plot an Indicator value from a higher Timeframe on your Chart. For most Indicators this is pretty straightforward however there is one Indicator that has been giving me quite a headache while trying to do this: The Average Directional Index . Anyway after going through almost 200 versions of this script I finally found a solution that works and thought I would share this with you, since I'm sure some of you have encountered the same problem.
How it works
Go to your desired Instrument/Timeframe and add the Script
Under Settings in the field for "Higher ADX TF" put the Timeframe-code you want to pull the ADX Values from.
- Codes: Monthly - M, Weekly W, Daily - D
- Codes Intraday: The amount of hours in minutes, e.g. if you want to pull values from the 4h-Chart the code is 240 (60 for 1h, 15 for 15m ...)
In some cases (see below) the calculation might not be correct. So make sure the values are correct:
a) Write down the latest ADX of the higher TF while you are on the lower TF
b) Switch the Resolution to the higher TF
c) Compare the value you have just written down to the next to last value. They should be the same.
d) Switch back the Resolution to the lower TF and you're good to go.
Limitations
You can only pull values from higher Timeframes, e.g. you're on a 4h Chart, so you can only pull values from the Daily, Weekly and Monthly Chart. You can't pull values from the 1h Chart.
You can only pull values from Timeframes, where the higher Timeframe Close always has a corresponding Close on the lower Timeframe, e.g. you can't pull values from the 3h Chart when you are on a 2h Chart. This should be pretty rare.
The Script needs a certain amount of Data from the Higher TF before the calculated values are correct. I have tested this on several Instruments and the Script usually needs approximately 100 Bars on the higher Timeframe (often less) for the values to be correct (error < 1%).
So when the difference between your lower Timeframe and you higher Timeframe is large, e.g. you want to pull the Daily ADX value on a 15m-Chart, the calculation can be wrong. This can lead to errors in 2 Cases:
a) Backtesting: When you go over old data and get close to the last available Bar the Data will be wrong. This will limit the amount of data you can backtest.
b) Live values: When the difference between the two Timeframes is too large, it is possible that even live values are wrong, e.g. this will be the case when you are trying to pull the Daily ADX value on a 5 minute Chart. Always check if the calculation works with your desired combination of Timeframes before using it (see above).
I hope this is useful for you and whish all of you successful trading!
Best regards
Kurbelklaus
Range Delta Heiken Ashi Bollinger|Buy/Sell |OB & OS CandlesPurpose: Mathematically represent buying and selling zones for Daily/ Weekly Traders
Indicator: Calculates moving average of the candle's body with respect to the daily trading range
Buy and Sell Signals: Calculates Bollinger Range with Max/Min and Buy/Sell Bollinger signals
Overbought and Oversold Signals: Candlesticks show overbought and oversold conditions
Level of Difficulty: This indicator was written to make life easier. Follow the Rules and anyone can use it.
Rule 1: Buy when candlestick is below "purple" line
Rule 2: Sell when candlestick is above "blue" line
Rule 3: Add bollinger bands to your currency chart
Rule 4: Confirm indicator bollinger bands with currency chart's bollinger bands
Rule 5: Trade in direction of trend
Rule 6: As with all trading; no indicators are fool proof. Please trade responsibly.
****Full Customization for you****
Suggestion 1: Add bollinger bands to currency chart to improve probability
Suggestion 2: Trade the direction of Trend
Suggestion 3: This indicator works very well with Ranged Markets (or use Suggestion 2)
Disclaimer 1: This Indicator words best on Daily and Weekly time frames
Disclaimer 2: Enjoy the Indicator and feel free to ADD COMMENTS; I worked very hard for you and me :)
Auto Pivots with S/R LevelsPlots out the pivot point with corresponding Support / Resistance levels.
It will automatically determine the time frame to calculate pivots based on the current view resolution.
Monthly resolution will pull a yearly pivot
Weekly resolution will pull a monthly pivot
Daily view will pull a weekly pivot
Intraday view will pull a daily pivot.
You have the choice of using Standard pivots or Fibonacci pivots
You can choose to only display the most recent pivot or all pivots
You can chose to extend the most recent pivot across the whole chart as a price line
TODO:
- Add in the ability to choose how far back historically to display pivots
- Add in calculations for smaller resolutions to calculate off lower time frames. EX: minute resolution should pull hour time frame to calculate pivots.
Herrick Payoff Index for Quandl DataUpdate to my previous Herrick Payoff Index script. This script pulls Quandl futures data with daily open interest. The prior version only used the weekly Commitment of Traders open interest data so could only be used on weekly bars. Note: Must use Quandl Symbol methodology in chart (i.e. enter symbol as QUANDL:CHRIS/CME_FC2, QUANDL:CME/FCX2016, ect.). Unfortunately, I haven't been able to program this to pull from the embedded futures data.
UCS_S_Stochastic Pop and Drop StrategyMy Contribution to Jake Bernstein Educational Series, Initiated by Chris Moody.
The Stochastic Pop was developed by Jake Bernstein and modified by David Steckler. Bernstein's original Stochastic Pop is a trading strategy that identifies price pops when the Stochastic Oscillator surges above 80. Steckler modified this strategy by adding conditional filters using the Average Directional Index (ADX) and the weekly Stochastic Oscillator.
Modifications
1. Weekly Stochastic Oscillator for Trading Bias = 5* Daily Stochastic
2. Optional Volume Confirmation, Custom Average Volume Length
Future Plans
1. Adding Triggers for Entry, Stops and Target. - This will be release when we have ability to code the complete Strategy. Although it can be done with the current pinescript options, it would be far more easier if we have strategy ability.
Link for Educational Purpose
stockcharts.com
-
Good Luck Trading
UCSgears
Realtime Squeeze Box [CHE] Realtime Squeeze Box — Detects lowvolatility consolidation periods and draws trimmed price range boxes in realtime to highlight potential breakout setups without clutter from outliers.
Summary
This indicator identifies "squeeze" phases where recent price volatility falls below a dynamic baseline threshold, signaling potential energy buildup for directional moves. By requiring a minimum number of consecutive bars in squeeze, it reduces noise from fleeting dips, making signals more reliable than simple threshold crosses. The core innovation is realtime box visualization: during active squeezes, it builds and updates a box capturing the price range while ignoring extreme values via quantile trimming, providing a cleaner view of consolidation bounds. This differs from static volatility bands by focusing on trimmed ranges and suppressing overlapping boxes, which helps traders spot genuine setups amid choppy markets. Overall, it aids in anticipating breakouts by combining volatility filtering with visual containment of price action.
Motivation: Why this design?
Traders often face whipsaws during brief volatility lulls that mimic true consolidations, leading to premature entries, or miss setups because standard volatility measures lag in adapting to changing market regimes. This design addresses that by using a hold requirement on consecutive lowvolatility bars to denoise signals, ensuring only sustained squeezes trigger visuals. The core idea—comparing rolling standard deviation to a smoothed baseline—creates a responsive yet stable filter for lowenergy periods, while the trimmed box approach isolates the core price cluster, making it easier to gauge breakout potential without distortion from spikes.
What’s different vs. standard approaches?
Reference baseline: Traditional squeeze indicators like the Bollinger Band Squeeze or TTM Squeeze rely on fixed multiples of bands or momentum oscillators crossing zero, which can fire on isolated bars or ignore range compression nuances.
Architecture differences:
Realtime box construction that updates barbybar during squeezes, using arrays to track and trim price values.
Quantilebased outlier rejection to define box bounds, focusing on the bulk of prices rather than full range.
Overlap suppression logic that skips redundant boxes if the new range intersects heavily with the prior one.
Hold counter for consecutive bar validation, adding persistence before signaling.
Practical effect: Charts show fewer, more defined orange boxes encapsulating tight price action, with a horizontal line extension marking the midpoint postsqueeze—visibly reducing clutter in sideways markets and highlighting "coiled" ranges that standard plots might blur with full highs/lows. This matters for quicker visual scanning of multitimeframe setups, as boxes selflimit to recent history and avoid piling up.
How it works (technical)
The indicator starts by computing a rolling average and standard deviation over a userdefined length on the chosen source price series. This deviation measure is then smoothed into a baseline using either a simple or exponential average over a longer window, serving as a reference for normal volatility. A squeeze triggers when the current deviation dips below this baseline scaled by a multiplier less than one, but only after a minimum number of consecutive bars confirm it, which resets the counter on breaks.
Upon squeeze start, it clears a buffer and begins collecting source prices barbybar, limited to the first few bars to keep computation light. For visualization, if enabled, it sorts the buffer and finds a quantile threshold, then identifies the minimum value at or below that threshold to set upper and lower box bounds—effectively clamping the range to exclude tails above the quantile. The box draws from the start bar to the current one, updating its right edge and levels dynamically; if the new bounds overlap significantly with the last completed box, it suppresses drawing to avoid redundancy.
Once the hold limit or squeeze ends, the box freezes: its final bounds become the last reference, a midpoint line extends rightward from the end, and a tiny circle label marks the point. Buffers and states reset on new squeezes, with historical boxes and lines capped to prevent overload. All logic runs on every bar but uses confirmed historical data for calculations, with realtime updates only affecting the active box's position—no future peeking occurs. Initialization seeds with null values, building states progressively from the first bars.
Parameter Guide
Source: Selects the price series (e.g., close, hl2) for deviation and box building; influences sensitivity to wicks or bodies. Default: close. Tradeoffs/Tips: Use hl2 for balanced range view in volatile assets; stick to close for pure directional focus—test on your timeframe to avoid oversmoothing trends.
Length (Mean/SD): Sets window for average and deviation calculation; shorter values make detection quicker but noisier. Default: 20. Tradeoffs/Tips: Increase to 30+ for stability in higher timeframes, reducing false starts; below 10 risks overreacting to singlebar noise.
Baseline Length: Defines smoothing window for the deviation baseline; longer periods create a steadier reference, filtering regime shifts. Default: 50. Tradeoffs/Tips: Pair with Length at 1:2 ratio for calm markets; shorten to 30 if baselines lag during fast volatility drops, but watch for added whips.
Squeeze Multiplier (<1.0): Scales the baseline downward to set the squeeze threshold; lower values tighten criteria for rarer, stronger signals. Default: 0.8. Tradeoffs/Tips: Tighten to 0.6 for highvol assets like crypto to cut noise; loosen to 0.9 in forex for more frequent but shallower setups—balances hit rate vs. depth.
Baseline via EMA (instead of SMA): Switches baseline smoothing to exponential for faster adaptation to recent changes vs. equalweighted simple average. Default: false. Tradeoffs/Tips: Enable in trending markets for quicker baseline drops; disable for uniform history weighting in rangebound conditions to avoid overreacting.
SD: Sample (len1) instead of Population (len): Adjusts deviation formula to divide by length minus one for smallsample bias correction, slightly inflating values. Default: false. Tradeoffs/Tips: Use sample in short windows (<20) for more conservative thresholds; population suits long looks where bias is negligible, keeping signals tighter.
Min. Hold Bars in Squeeze: Requires this many consecutive squeeze bars before confirming; higher denoise but may clip early setups. Default: 1. Tradeoffs/Tips: Bump to 35 for intraday to filter ticks; keep at 1 for swings where quick consolidations matter—trades off timeliness for reliability.
Debug: Plot SD & Threshold: Toggles lines showing raw deviation and threshold for visual backtesting of squeeze logic. Default: false. Tradeoffs/Tips: Enable during tuning to eyeball crossovers; disable live to declutter—great for verifying multiplier impact without alerts.
Tint Bars when Squeeze Active: Overlays semitransparent color on bars during open box phases for quick squeeze spotting. Default: false. Tradeoffs/Tips: Pair with low opacity for subtlety; turn off if using boxes alone, as tint can obscure candlesticks in dense charts.
Tint Opacity (0..100): Controls background tint strength during active squeezes; higher values darken for emphasis. Default: 85. Tradeoffs/Tips: Dial to 60 for light touch; max at 100 risks hiding price action—adjust per chart theme for visibility.
Stored Price (during Squeeze): Price series captured in the buffer for box bounds; defaults to source but allows customization. Default: close. Tradeoffs/Tips: Switch to high/low for wider boxes in gappy markets; keep close for midline focus—impacts trim effectiveness on outliers.
Quantile q (0..1): Fraction of sorted prices below which tails are cut; higher q keeps more data but risks including spikes. Default: 0.718. Tradeoffs/Tips: Lower to 0.5 for aggressive trim in noisy assets; raise to 0.8 for fuller ranges—tune via debug to match your consolidation depth.
Box Fill Color: Sets interior shade of squeeze boxes; semitransparent for layering. Default: orange (80% trans.). Tradeoffs/Tips: Soften with more transparency in multiindicator setups; bold for standalone use—ensures boxes pop without overwhelming.
Box Border Color: Defines outline hue and solidity for box edges. Default: orange (0% trans.). Tradeoffs/Tips: Match fill for cohesion or contrast for edges; thin width keeps it clean—helps delineate bounds in zoomed views.
Keep Last N Boxes: Limits historical boxes/lines/labels to this count, deleting oldest for performance. Default: 10. Tradeoffs/Tips: Increase to 50 for weekly reviews; set to 0 for unlimited (risks lag)—balances history vs. speed on long charts.
Draw Box in Realtime (build/update): Enables live extension of boxes during squeezes vs. waiting for end. Default: true. Tradeoffs/Tips: Disable for confirmedonly views to mimic backtests; enable for proactive trading—adds minor repaint on live bars.
Box: Max First N Bars: Caps buffer collection to initial squeeze bars, freezing after for efficiency. Default: 15. Tradeoffs/Tips: Shorten to 510 for fast intraday; extend to 20 in dailies—prevents bloated arrays but may truncate long squeezes.
Reading & Interpretation
Squeeze phases appear as orange boxes encapsulating the trimmed price cluster during lowvolatility holds—narrow boxes signal tight consolidations, while wider ones indicate looser ranges within the threshold. The box's top and bottom represent the quantilecapped high and low of collected prices, with the interior fill shading the containment zone; ignore extremes outside for "true" bounds. Postsqueeze, a solid horizontal line extends right from the box's midpoint, acting as a reference level for potential breakout tests—drifting prices toward or away from it can hint at building momentum. Tiny orange circles at the line's start mark completion points for easy scanning. Debug lines (if on) show deviation hugging or crossing the threshold, confirming hold logic; a persistent hug below suggests prolonged calm, while spikes above reset counters.
Practical Workflows & Combinations
Trend following: Enter long on squeezeend close above the box top (or midpoint line) confirmed by higher high in structure; filter with rising 50period average to avoid countertrend traps. Use boxes as support/resistance proxies—short below bottom in downtrends.
Exits/Stops: Trail stops to the box midpoint during postsqueeze runs for conservative holds; go aggressive by exiting on retest of opposite box side. If debug shows repeated threshold grazes, tighten stops to curb drawdowns in ranging followups.
Multiasset/MultiTF: Defaults work across stocks, forex, and crypto on 15min+ frames; scale Length proportionally (e.g., x2 on hourly). Layer with highertimeframe boxes for confluence—e.g., daily squeeze + 1H box for entry timing. (Unknown/Optional: Specific multiTF scaling recipes beyond proportional adjustment.)
Behavior, Constraints & Performance
Repaint/confirmation: Core calculations use historical closes, confirming on bar close; active boxes repaint their right edge and levels live during squeezes if enabled, but freeze irrevocably on hold limit or end—mitigates via barbybar buffer adds without future leaks. No lookahead indexes.
security()/HTF: None used, so no external timeframe repaints; all native to chart resolution.
Resources: Caps at 300 boxes/lines/labels total; small arrays (up to 20 elements) and short loops in sorting/minfinding keep it light—suitable for 10k+ bar charts without throttling. Persistent variables track state across bars efficiently.
Known limits: May lag on ultrasharp volatility spikes due to baseline smoothing; gaps or thin markets can skew trims if buffer hits cap early; overlaps suppress visuals but might hide chained squeezes—(Unknown/Optional: Edge cases in nonstandard sessions).
Sensible Defaults & Quick Tuning
Start with defaults for most liquid assets on 1Hdaily: Length 20, Multiplier 0.8, Hold 1, Quantile 0.718—yields balanced detection without excess noise. For too many false starts (choppy charts), increase Hold to 3 and Baseline Length to 70 for stricter confirmation, reducing signals by 3050%. If squeezes feel sluggish or miss quick coils, shorten Length to 14 and enable EMA baseline for snappier adaptation, but monitor for added flips. In highvol environments like options, tighten Multiplier to 0.6 and Quantile to 0.6 to focus on core ranges; reverse for calm pairs by loosening to 0.95. Always backtest tweaks on your asset's history.
What this indicator is—and isn’t
This is a volatilityfiltered visualization tool for spotting and bounding consolidation phases, best as a signal layer atop price action and trend filters—not a standalone predictor of direction or strength. It highlights setups but ignores volume, momentum, or news context, so pair with discreteness rules like higher highs/lows. Never use it alone for entries; always layer risk management, such as 12% stops beyond box extremes, and position sizing based on account drawdown tolerance.
Disclaimer
The content provided, including all code and materials, is strictly for educational and informational purposes only. It is not intended as, and should not be interpreted as, financial advice, a recommendation to buy or sell any financial instrument, or an offer of any financial product or service. All strategies, tools, and examples discussed are provided for illustrative purposes to demonstrate coding techniques and the functionality of Pine Script within a trading context.
Any results from strategies or tools provided are hypothetical, and past performance is not indicative of future results. Trading and investing involve high risk, including the potential loss of principal, and may not be suitable for all individuals. Before making any trading decisions, please consult with a qualified financial professional to understand the risks involved.
By using this script, you acknowledge and agree that any trading decisions are made solely at your discretion and risk.
Do not use this indicator on HeikinAshi, Renko, Kagi, PointandFigure, or Range charts, as these chart types can produce unrealistic results for signal markers and alerts.
Best regards and happy trading
Chervolino
Position Sizer (Share Qty)
This indicator enables fast & accurate position sizing for traders using (user defined) fixed dollar risk, eliminating the need for manual calculations and supporting disciplined risk management directly on the chart
Calculates precise share quantity for fixed-risk trades using the formula Shares = Risk Amount / (Current Price – Stop Price), rounded to the nearest whole share, updating in real time on every bar
Offers two dynamic stop-loss options: Low of Day (LoD) — tracked only during Regular Trading Hours (9:30 AM – 4:00 PM ET) with automatic daily reset — or Low of Week (LoW) via weekly timeframe data
Displays all critical trade data in a clean, customizable on-screen table showing: Risk Amount, Stop Loss type (LoD/LoW), Stop Price, and calculated Shares Qty
Allows full table placement control with four corner positions with optional Top Offset and Bottom Offset (0–20 blank rows each) to prevent overlap with price action or other indicators
Provides complete visual styling control for header text/background, value text/background, and share quantity text/background
Ensures efficient rendering by recreating the table only when position, row count, or layout changes, deleting the prior instance to avoid flicker or memory issues
Handles edge cases safely: shows 0 shares if stop is 'na' or above current price, and initializes LoD only on the first RTH bar of each session
For use on equities only (table will not display on futures instruments)
--
Future improvements:
Visual Stop Loss line for either LoD or LoW
Functionality and toggle to include Extended hours (PM /AH) for LoD stop pricing
Traderei SessionsTraderei Sessions shows the previous daily H/L + previous weekly H + L, daily open from the current day, the H/L from Asia/London/NY Session, including the 50% Level for Premium or Discount Price.
VPOC for each Session. VPOC do not work on FX ! only Crypto + Gold !
2 EMAs and 1 SMA, + 1 additional EMA/SMA.
default settings for EMA 20/50, SMA 200
all lines, labels can be toggled
Day of Week LetterLetters printed on the Daily candle corresponding the day of the trading week it is on. Used for weekly range logic
Set it to 'bring to front' to see it
PDH PDL Open ClosePDH/PDL/Open/Close Levels Indicator
Overview
This Pine Script indicator plots the Previous Day High (PDH), Previous Day Low (PDL), Previous Day Open (PDO), and Previous Day Close (PDC) levels on your chart. It's designed for traders who rely on key daily levels to identify potential support, resistance, and intraday reference points. The indicator supports multiple timeframes, allowing you to visualize these levels from higher timeframes (e.g., weekly or monthly) directly on lower timeframe charts.
Built with Pine Script v6, it's lightweight, customizable, and overlays seamlessly on any symbol. Lines extend slightly into the future for better visibility, and labels provide clear identification with price values.
Key Features
- Multi-Timeframe Support: Choose from predefined timeframes (5m to 1M) via the input settings to fetch and plot levels from the selected period.
- Clean Visualization:
- PDH and PDL: Solid black lines for high/low levels.
- PDO: Dotted blue line for the opening price.
- PDC: Dotted red line for the closing price.
- Dynamic Labels: Automatically placed at the end of each line, showing the timeframe and exact price (e.g., "1D High: 150.25").
- Efficient Updates: Lines and labels update in real-time without cluttering the chart—old elements are automatically cleaned up.
- Extension Handling: Lines extend 2 bars ahead by default, adjustable if needed via code modifications.
How to Use
1. Add to Chart**: Copy the script into TradingView's Pine Editor, save, and add it to your chart.
2. Customize Timeframe: In the indicator settings, select your desired timeframe (default: 1D). This pulls levels from the previous period of that timeframe.
3. Interpret Levels:
- Use PDH/PDL as potential resistance/support zones.
- PDO/PDC can highlight session biases (e.g., gap fills or continuation patterns).
- Ideal for day trading, swing setups, or aligning with higher timeframe context.
4. Best Practices: Works on any market (stocks, forex, crypto). Combine with volume or momentum indicators for confluence.
Settings
- Timeframe: Dropdown with options: 5m, 10m, 15m, 30m, 45m, 1H, 2H, 3H, 4H, 1D, 1W, 1M.
- No other inputs for simplicity—colors, styles, and extensions are hardcoded for a clean default look. Edit the script to tweak (e.g., line colors or extension length).
PIVOT-V.13 05-09-25This Pine Script automatically detects pivot levels and generates buy/sell signals based on price action around those pivots. It identifies key support and resistance zones derived from previous period highs, lows, and closes, then marks optimal entry, target, and stop-loss levels on the chart.
The script is designed to assist traders in systematic decision-making using pivot-based strategies.
🔍 Core Features
Automatic Pivot Detection: Calculates and updates pivots in real-time using standard formulas.
Smart Trade Setup:
Buy Signal: Triggered when price action confirms strength above a pivot or resistance level.
Sell Signal: Triggered when price action confirms weakness below a pivot or support level.
Entry, Target & Stop-Loss Levels: Automatically plots potential entry points, stop-loss levels, and take-profit zones based on the nearest pivot structure.
Customizable Settings:
Choose pivot type and timeframe (daily, weekly, or monthly).
Adjust risk ratio, stop size, and confirmation filters.
Enable/disable visual labels or alerts.
Visual Clarity: Clearly marks all pivot levels and trade signals on the chart with colored labels and lines.
🎯 Purpose
This script helps traders quickly identify high-probability entry zones and maintain disciplined trade management by following pre-defined pivot-based rules — reducing emotional bias and enhancing consistency.






















