JustaBox_NY_LexThis indicator marks two boxes around the opening hour of the chosen session(s). One around the highs and lows and one around the highest open/close and lowest open/close for that hour., its main purpose if for backtesting the DR/IDR strategy but is useful for live trading as it auto adds the boxes and STD levels. The buy and sell signals that show up are not meant for trade entries, they just give an idea of whether there was a signal that day which is a close above or below the IDR (inner box lines), from there loops are started and it tests which STD levels get hit or if the opposite end of the box is crossed it considers it a stop out and closes the loops. The data from these loops can be pulled to email and then excel using the alert system.
This is the first thing i've ever coded, I put alot of work into it but id recommend going thru a few days randomly and checking the data matches up as expected.
This indicator only pulls data from the NY session, I have two others of identical functionality, the only difference being they pull the data from the London and Tokyo sessions respectively, wanted to include all three in one but I reached a limit. Search JustaBox_LDN_Lex and JustaBox_TKO_Lex
When live, once the hour of the chosen session resolves it marks the DR and IDR lines onward for a few hours, adds a 0.5 retracement line in the middle and STD levels above and below at 0.5, 1, 1.5, 2, 2.5, & 3.
There are labels that can be turned off, they show the prices these lines are set at.
Read the tooltips in the menu for more information.
(Might be self explanatory when you pull it but I'll add a key here for the titles of the data(had to keep them short due to character limit) and explain how the test works in the next couple of days but quickly:
Each STD levels has a true, false or NaN state, if its a buy signal for the session the STD levels below the bottom DR are turned off and will return NaN, but if its a sell signal they'll return false if they don't get hit true if they do. Each level has a cross time this is a bar number, you also get a bar number for the last bar in the DR box and one for when you received the buy or sell signal, so you subtract one of these from the STD X number and it will give you number of bars since 10:30 for NY sess or from when you received signal. Multiply that number by 5 to get the number of minutes. Gives prices for boxes, open and close prices of first and last candles in box and price of the NY day open for all sessions)
ค้นหาในสคริปต์สำหรับ "sessions"
RF+ Divergence Scalping SystemRF+ Divergence Scalping System + Custom Signals + Alerts.
This chart overlay indicator has been developed for the low timeframe divergence scalper.
Built upon the realtime divergence drawing code from the Divergence for Many indicator originally authored by Lonsometheblue, this chart overlay indicator bundles several additional unique features and modifications to serve as an all-in-one divergence scalping system. The current key features at the time of publishing are listed below (features are optional and can be enabled or disabled):
- Fully configurable realtime divergence drawing and alerting feature that can draw divergences directly on the chart using data sourced from up to 11 oscillators selected by the user, which have been included specifically for their ability to detect divergences, including oscillators not presently included in the original Divergence for Many indicator, such as the Ultimate Oscillator and TSI.
- Optional on chart table showing a summary of key statuses of various indicators, and nearby divergences.
- 2 x Range Filters with custom settings used for low timeframe trend detection.
- 3 x configurable multi-timeframe Stochastic RSI overbought and oversold signals with presentation options.
- On-chart pivot points drawn automatically.
- Automatically adjusted pivot period for up to 4 configurable time frames to fine tune divergences drawn for optimal divergence detection.
- Real-price line for use with Heikin Ashi candles, with styling options.
- Real-price close dots for use with Heikin Ashi candles, with styling options.
- A selection of custom signals that can be printed on-chart and alerted.
- Sessions indicator for the London, New York, Tokyo and Sydney trading sessions, including daylight savings toggle, and unique ‘invert background color’ option, which colours the entire chart - except the trading session you have selected, leaving your chart clear of distracting background color.
- Up to 4 fully configurable moving averages.
- Additional configurable settings for numerous built in indicators, allowing you to alter the lengths and source types, including the UO, TSI, MFI, TSV, 2 x Range Filters.
- Configurable RSI Trend detection signal filter used in a number of the signals, which filters buy signals where the RSI is over the RSI moving average, and only prints sell signals where RSI is under the moving average.
- Customisable on-chart watermark, with inputs for a custom title, subtitle, and also an optional symbol | timeframe | date feature.
The Oscillators able to be selected for use in drawing divergences at the time of publishing are as follows:
- Ultimate Oscillator (UO)
- True Strength Indicator (TSI)
- Money Flow Index (MFI)
- Cumulative Delta Volume (CDV)
- Time Segmented Volume (TSV)
- Commodity Channel Index (CCI)
- Awesome Oscillator
- Relative Strength Index (RSI)
- Stochastic
- On Balance Volume (OBV)
- MACD Histogram
What are divergences?
Divergence is when the price of an asset is moving in the opposite direction of a technical indicator, such as an oscillator, or is moving contrary to other data. Divergence warns that the current price trend may be weakening, and in some cases may lead to the price changing direction.
There are 4 main types of divergence, which are split into 2 categories;
regular divergences and hidden divergences. Regular divergences indicate possible trend reversals, and hidden divergences indicate possible trend continuation.
Regular bullish divergence: An indication of a potential trend reversal, from the current downtrend, to an uptrend.
Regular bearish divergence: An indication of a potential trend reversal, from the current uptrend, to a downtrend.
Hidden bullish divergence: An indication of a potential uptrend continuation.
Hidden bearish divergence: An indication of a potential downtrend continuation.
Setting alerts.
With this indicator you can set alerts to notify you when any/all of the above types of divergences occur, on any chart timeframe you choose, also when the triple timeframe Stochastic RSI overbought and oversold confluences occur, as well as when custom signals are printed.
Configurable pivot period values.
You can adjust the default pivot period values to suit your prefered trading style and timeframe. If you like to trade a shorter time frame, lowering the default lookback values will make the divergences drawn more sensitive to short term price action. By default, this indicator has enabled the automatic adjustment of the pivot periods for 4 configurable time frames, in a bid to optimize the divergences drawn when the indicator is loaded onto any of the 4 time frames selected. These time frames and their associated pivot periods can be fully reconfigured within the settings menu. By default, these have been further optimized for the low timeframe scalper trading on the 1-15 minute time frames.
How do traders use divergences in their trading?
A divergence is considered a leading indicator in technical analysis , meaning it has the ability to indicate a potential price move in the short term future.
Hidden bullish and hidden bearish divergences, which indicate a potential continuation of the current trend are sometimes considered a good place for traders to begin, since trend continuation occurs more frequently than reversals, or trend changes.
When trading regular bullish divergences and regular bearish divergences, which are indications of a trend reversal, the probability of it doing so may increase when these occur at a strong support or resistance level . A common mistake new traders make is to get into a regular divergence trade too early, assuming it will immediately reverse, but these can continue to form for some time before the trend eventually changes, by using forms of support or resistance as an added confluence, such as when price reaches a moving average, the success rate when trading these patterns may increase.
Typically, traders will manually draw lines across the swing highs and swing lows of both the price chart and the oscillator to see whether they appear to present a divergence, this indicator will draw them for you, quickly and clearly, and can notify you when they occur.
How do traders use overbought and oversold levels in their trading?
The oversold level is when the Stochastic RSI is above the 80 level is typically interpreted as being 'overbought', and below the 20 level is typically considered 'oversold'. Traders will often use the Stochastic RSI at, or crossing down from an overbought level as a confluence for entry into a short position, and the Stochastic RSI at, or crossing up from an oversold level as a confluence for an entry into a long position. These levels do not mean that price will necessarily reverse at those levels in a reliable way, however. This is why this version of the Stoch RSI employs the triple timeframe overbought and oversold confluence, in an attempt to add a more confluence and reliability to this usage of the Stoch RSI.
This indicator is intended for use in conjunction with related panel indicators including the TSI+ (True Strength Indicator + Realtime Divergences), UO+ (Ultimate Oscillator + Realtime Divergences), and optionally the STRSI+ (MTF Stochastic RSI + Realtime Divergences) and MFI+ (Money Flow Index + Realtime Divergences) available via this authors’ Tradingview profile, under the scripts section. The realtime divergence drawing code will not identify all divergences, so it is suggested that you also have panel indicators to observe. Each panel indicator also offers additional means of entry confirmation into divergence trades, for example, the Stochastic can indicate when it is crossing down from overbought or up from oversold, the TSi can indicate when the 2 TSI bands cross over one another upward or downward, and the UO and MFI can indicate an entry confluence when they are nearing, or crossing their centerlines, for more confidence in your divergence trade entries.
Additional information on the settings for this indicator can be found via the tooltips within the settings menu itself. Further information on feature updates, and usage tips & tricks will be added to the comments section below in due course.
Disclaimer: This indicator uses code adapted from the Divergence for Many v4 indicator authored by Lonesometheblue, and several stock indicators authored by Tradingview. With many thanks.
1+KillZoneLiteRemove plot line for a better view. I've made this to work on "US30 Global Prime" probably works on other pairs the codes left open to mod.
This Indicator shows 3 sessions to help you focus on timing. This will help you with learning pattern recognition aswell.
1. Gray zone is spreads. The gray zone will show up 30 min before spreads open up.
2. Blue is new york
3. Red is london reversal zone.
4. Look between the zones and also how price reacts within the zones and at what time.
5. This indicator also prints the sessions 1 day in advance to help with back testing aswell.
Phantom - My Session RangeThis is a modification of a script by RobMinty, "FXN - Asian Session Range" The script provides functionality to track specific trading sessions based on user preference rather than just the market sessions open and close. The idea is to help you hold yourself accountable to your specific trading times as well as backtest various marketing timings suitable to your schedule.
This script utilizes RobMinty's pine code to visualize your market session. We have adjusted the script to project the end of the session before the candles print - as well as adding/subtracting the horizontal and/or vertical lines around the current session box. This should help you understand how much time you have left in your session with a quick visual representation. While we have made some additions and adjustments to RobMinty's script- The inputs and functions of the combined script have not changed significantly from the originals. Like the originals, the code has been made open-source. If this script is reused or modified, please provide credit to RobMinty. If you plan to use this specific code with the ability to remove lines from the box and project session end forward, please credit both of us.
FULL MA Optimization ScriptHello!
This script measures the performance of 10 moving averages and compares them!
Crossover and crossunders are both tested.
The tested moving averages include: TEMA, DEMA, EMA, SMA, ALMA, HMA, T3 Average, WMA, VWMA, LSMA.
You can select the length of the moving averages and the data source (I.E, close, open, ohlc4, etc.) and the script will calculate your selections!
For instance, if you select a length of 32 and a source of ohlc4 for crossovers, the script will assign the ten moving averages that length and data source and compare the performance for ohlc4 crossovers of the 32TEMA, 32DEMA, 32SMA, 32WMA, etc. If you select crossunder, the script will calculate the performance of ohlc4 crossunders of the same moving average lengths.
Moving average performances are listed in descending order (best to worst) and are categorized by tier: Upper-Tier, Mid-Tier, Lower-Tier. The Upper-Tier displays the three best performing averages relative to the MA length and data source, for the asset on the relevant chart timeframe. The Lower-Tier displays the three worst performing averages. The Mid-Tier displays the moving averages whose performance did not achieve a top three spot or a bottom three spot.
Also calculated is the moving average which achieved the highest cumulative gain/loss and the lowest cumulative gain/loss. Any asset and timeframe can be tested; the script recalculates relative to the chart timeframe. I added a "Benchmark Moving Average" free parameter and a "Custom Moving Average" free parameter. The two operate identically; you can set the length and data source of both for quick and simple comparison between differing average lengths and sources.
If "Crossover" is selected, the "(X Candles)" displayed on the tables reflects the average number of sessions the data source remains above a moving average following a crossover. If "Crossunder" is selected, the "(X Candles)" reflects the average number of sessions the data source remains below the moving average following a crossunder.
If "Crossover" is selected, the listed "X%" reflects the average percentage gain/loss following a source crossover of a moving average up until the source crosses back under the moving average. If "Crossunder" is selected, the listed "X%" reflects the average percentage gain/loss following a source crossunder of a moving average up until the source crosses back over the moving average.
If "Crossover" is selected, the listed "X Crosses" reflects the number of instances in which the source crossed over a moving average. If "Crossunder" is selected, the listed "X Crosses" reflects the number of instances in which the source crossed under a moving average.
Additional tooltips and instructions are included should you access the user input menu.
The moving averages can be plotted as a gradient (highest priced MA to lowest priced MA) alongside the best performing moving average. The moving averages can be plotted in full color, light color alongside the best performing average, or not plotted.
This script improves upon a similar script I have released:
I decided not to update the previous script. The previous script calculates crossovers only and, due to being less code intensive, calculates much quicker. If a user is concerned only with price crossovers, not crossunders, the original script is a better option! It's faster, making it the preferable choice!
This script "FULL MA Optimization" calculates crossovers/crossunders and incorporates additional plot styles. I ran into trouble a few times where the script was too large to run on TV. This script is not "slow", I suppose; however, calculations and parameter modifications take a bit longer than the original script!
SetSessionTimesLibrary "SetSessionTimes"
Function to automatically set session times for symbols and eventually timezone.
Useful mainly for futures contracts, to differentiate between pit and overnight sessions, and for 24 hours symbols if you want to "create" sessions for them
This library only returns correct session times to the calling script and does nothing by itself on the chart. the calling script must then use the returned session times to do anything.
For example, in the attached chart this library is used by my initial balance indicator, which calls it to retrieve the correct session times for the selected symbol in the chart, given that different futures contracts have different pit session times (RTH times) and Tradingview hasn't implemented that yet.
SetSessionTimes()
Koalafied Initial Balance Levels and ExtensionsShows the Initial Balance and range extensions for either the Daily session or individual market sessions (Asia, London, New York).
Initial Balance is the range represented by the first two segments (typically half-hour segments) of a trading session. Range extensions are a function of the longer-term trader participation, pushing price outside of the beginning 'fair' range established by the local traders. With the introduction of 24/7 markets the initial balance is often now regarded as less important than in the past, however re-calculating IB for multiple trading sessions may reinstitute insight to Market Direction and Confidence
Kviateq - Session PivotsFirst of all, I must say that this script wouldn't be possible without the help of one of the best script developers on TradingView - @ahancock (thanks a bunch for your help)
This script draws opening ranges for each of the sessions - Tokyo, London and New York and plots session high, low and pivot range of the previous session.
So if you trade London session - you would only take longs if we're above the Tokyo pivot range and vice versa for shorts.
Often times previous session's highs act as resistance and lows act as support, so careful trading around those levels.
It is obviously meant for lower timeframes, since each of the sessions only lasts a few hours.
Default settings are set to the exchange that I use and my timezone (GMT +7), so you might need to adjust the settings accordingly.
Tokyo - 12am GMT
London - 7am GMT
New York - 12pm GMT
Historic VPoCs and pseudo VPVRThis study tries to recreate session based historic VPoCs
and VPVR Volume Profile
as they are used by
TradingLatino TradingView user.
It's aimed at BTCUSDT pair and 4h timeframe.
HOW IT WORKS
HOW IT WORKS - VPVR Profile Block
It gathers volume from the last chosen Bars
in order to draw the vpvr profile block
Volume that intersects with current level range
being studied is added to its value.
Additionally the current level price is modified
so that it matches the level price where most
of the volume has concentrated
So you get a pretty accurate price for drawn volume
while at the same time the levels are not stuck
to arbitrary level prices.
HOW IT WORKS - VPoC
It calculates a Volume Profile for the
given historic session but then
it only outputs that Volume Profile VPoC.
SETTINGS
Show VPVR Volume Profile {True}.
Show Historic VPoC lines {True}.
Show Historic VPoC labels {True}.
Extend Historic VPoC lines {True}: If this option is turned off the VPoC lines are only shown during the session duration.
Show tick difference from current price {False}: BETA. Feedback is needed because I'm not sure how it should work this setting.
VPVR Number of bars {100}: Define the Visible Range in number of bars so that its Volume Profile can be shown.
VPVR Profile width (in bars) {15}: VPVR Profile can be make larger or smaller in width thanks to this option.
VPVR Profile offset (in bars) {15}: VPVR Profile can be shown more to the left or to the right if the defaults do not suit you.
Historic Session Volume Profile timeframe {1D}: Historic VPoC use 1 day as their timeframe reference by default.
Number of decimal digits {2}: How many decimal digits are shown in label prices.
Number of previous sessions to print VPoC {5}: How many previous sessions VPoCs are to be printed. The maximum for this setting is 20.
Historic VPoC lines width (in pixels) {2}.
Historic VPoC labels size {small}.
History VPoC line offset (in bars) {5}: How far to the right VPoCs lines are to be extended. Note: This setting does not apply when 'Extend Historic VPoC lines' is set to 'False'.
WARNING
Please be aware that VPoC from the first previous session might not be accurate due to Pine Script limitations.
VPVR USAGE
This is not a VPVR like the official TradingView indicator.
This is a pseudo VPVR and that means it needs some manual input from you.
But, don't worry it's quite easy to do and if you always use the same number
of bars to calculate your VPVR then you might even just set it up once.
In order to show the VPVR (or Volume Profile on the Visible Range):
Rescale your chart so that you see all the bars for your Visible Range.
Click on the ruler tool.
Click on the last bar (far to the right) shown on the screen
Drag the ruler to first bar (far to the left) shown on the screen
Check what the ruler says
E.g. it says: 101 bars
Open this study settings
Modify: 'VPVR Number of bars ' setting
So that its value matches your measured number of bars (101)
Press OK to confirm and wait for the indicator to refresh.
STRATEGY USAGE
If your strategy uses VPoC
to define your resistances
or supports
you can check the VPoCs shown here.
FEEDBACK
I have only used this identifier in BTCUSDT 4h timeframe.
I'm interested to know what needs to be tweaked
in other securities and timeframes.
PINE STUDY TRICK
This study let's you choose the number of decimals the label will use.
CREDITS
I have reused and adapted some code from
'Poor man's volume profile' study
which it's from TradingView IldarAkhmetgaleev user.
I also wanted to thank him for helping me understanding his study.
I have reused some code from
'MTF Selection Framework - PineCoders FAQ' study
which it's from TradingView PineCoders user.
Session S/RThis indicator marks the resistances and supports of the post, pre and market sessions of the previous day projecting up to the market of the day, also it marks the hours of these three markets allowing to identify the beginning and end of the sessions in London, Hong Kong, and America.
RVOL - R4RocketRelative volume or RVOL for short is an indicator that is used to measure how 'In Play' the stock is. Simply put, it helps to quantify how interested everybody is in the given stock - higher the value, higher the interest and hence higher is the probability for movement in the stock.
I have tried to create RVOL (Relative Volume ) Indicator as per the description that I read on SMB Capital blog. The blog is a great resource.
...................................................................................................................................................................................
How to use the indicator - The indicator is meant for INTRADAY ONLY.
The indicator has following inputs -
1. RVOL Period - Value from 3 to 14 (Default Value = 4)
This is used to calculate the average volume over the given period of days. e.g. average volume for the last 5 days, last 3 days, last 10 days etc. NOTE - If you use higher RVOL Period on smaller timeframes, the code will give an error. So I recommend using 4 or lower for 5 min timeframe. (Nothing will work on 1 min chart and you can experiment for other timeframes.)
2. RVOL Sectional - True / False (Default Value = False)
If you check this box then you will be able to calculate the RVOL for a particular session (or between particular sessions) in that trading day.
What do I mean by session?
Well I have divided the trading day into 6 (almost) equally spaced sessions in time, i.e. 6 hours and 15 mins (for NSE - India) of trading day is divided into 1 hr - 1st session, 1 hr - 2nd session, 1 hr - 3rd session, 1 hr - 4th session, 1 hr - 5th session, 1 hr and 15 min - 6th session.
Before using 3rd and 4th inputs of indicator, RVOL Sectional box MUST BE CHECKED FIRST.
3. RVOL From Session - 1 to 6 (Default Value = 1)
4. RVOL To Session - 1 to 6 (Default Value = 2)
Now if you select 2 in "RVOL From Session" input and 3 in "RVOL To Session" input, the indicator will calculate RVOL for the 2nd and 3rd hour of the trading day. If you select 3 in both the inputs, then the indicator will give RVOL for the 3rd hour of the trading day.
5. RVOL Trigger - 0.2 to 10 (Default Value = 2)
Filter to find days having RVOL above that value. The indicator turns green (or colour of your choice) when RVOL is more than "RVOL Trigger".
...................................................................................................................................................................................
Hope this indicator will add some value in your trading endeavor.
“Only The Game, Can Teach You The Game” – Jesse Livermore
Yours sincerely,
R4Rocket
**If you have some awesome idea for improvement of the indicator - request you to update the code and share the same.
TRADING VIEW INDICATOR - PINE TUTORIAL 5After a long gap, I have written the 5th tutorial for the pine script. You can find the others below, if you read through all of these you should be good to do your own writing.
This script mimics the Trading View Indicator . For example this one below.
www.tradingview.com
It shows the net result of the 28 indicator, either as buy or sell. I have worked hard to make sure it matches the trading view results but I am not in hundred percent agreement with tradingView on SMA, EMA and Ichimoku indicator.
There are many commented plots because I needed to check separately if each indicator is working correctly.
Someone else wrote this code but they did not make it public. It took me about 3 weeks to write this and to be honest it could be cleaner and better commented.
If you find any mistake please let me know. I hope it will be useful in your learning.
Sim PackThis is a custom indicator that includes the following:
EMA's 50, 100 and 200
SMA 20
Moving average cross support and resistance levels
Colored bars associated with 4-hour AM sessions for Asia, UK, and US
1-hour alerts prior to AM sessions
Plots of previous AM session close during current AM session
Session TimeZonesThis indicators show background colours to identify world timezones
New York, London, Tokio, China and Sydney sessions
You can also setup timeframe intervals to show or hide.
Time Values based on UTC: ** YOU HAVE TO SETUP YOUR CHARTS TO 0-UTC TIMEZONE **
Values from: en.wikipedia.org
New York: UTC-5
Market Session: 09:30 - 16:00 (Local Time)
Market Session: 14:30 - 21:00 (UTC Based Time)
London: UTC
Market Session: 08:00 - 16:30 (Local Time)
Market Session: 08:00 - 16:30 (UTC Based Time)
Tokyo: UTC+9
Market Session: 09:00 - 15:00 (Local Time)
Market Session: 00:00 - 06:00 (UTC Based Time)
China: UTC+8
Market Session: 09:30 - 16:00 (Local Time)
Market Session: 01:30 - 08:00 (UTC Based Time)
Sydney: UTC+10
Market Session: 10:00 - 16:00 (Local Time)
Market Session: 00:00 - 06:00 (UTC Based Time)
Can be used to know from what time of the world they are traders awake or
to search correlations between big moves and timezones hours.
Thanks to:
www.tradingcode.net
01/06/2018
Crude Roll Trade SimulatorEDIT : The screen cap was unintended with the script publication. The yellow arrow is pointing to a different indicator I wrote. The "Roll Sim" indicator is shown below that one. Yes I could do a different screen cap, but then I'd have to rewrite this and frankly I don't have time. END EDIT
If you have ever wanted to visualize the contango / backwardation pressure of a roll trade, this script will help you approximate it.
I am writing this description in haste so go with me on my rough explanations.
A "roll trade" is one involving futures that are continually rolled over into future months. Popular roll trade instruments are USO (oil futures) and UVXY (volatility futures).
Roll trades suffer hits from contango but get rewarded in periods of backwardation. Use this script to track the contango / backwardation pressure on what you are trading.
That involves identifying and providing both the underlying indexes and derivatives for both the front and back month of the roll trade. What does that mean? Well the defaults simulate (crudely) the UVXY roll trade: The folks at Proshares buy futures that expire 60 days away and then sell those 30 days later as short term futures (again, this is a crude description - see the prospectus) and we simulate that by providing the Roll Sim indicator the symbols VIX and VXV along with VIXY and VIXM. We also provide the days between the purchase and sale of the rolled futures contract (in sessions, which is 22 days by my reckoning).
The script performs ema smoothing and plots both the index lines (VIX and VXV as solid lines in our case) and the derivatives (VIXY and VIXM as dotted lines in our case) with the line graphs offset by the number of sessions between the buy and sell. The gap you see represents the contango / backwardation the derivative roll trades are experiencing and gives you an idea how much movement has to happen for that gap to widen, contract or even invert. The background gets painted red in periods of backwardation (when the longer term futures cost less than when sold as short term futures).
Fortunately indexes are calibrated to the same underlying factors, so their values relative to each other are meaningful (ie VXV of 18 and VIX of 15 are based on the same calculation on premiums for S&P500 symbols, with VXV being normally higher for time value). That means the indexes graph well without and adjustments needed. Unfortunately derivatives suffer contango / backwardation at different rates so the value of VIXY vs VIXM isn't really meaningful (VIXY may take a reverse split one year while VIXM doesn't) ... what is meaningful is their relative change in value day to day. So I have included a "front month multiplier" which can be used to get the front month line "moved up or down" on the screen so it can be compared to the back month.
As a practical matter, I have come to hide the lines for the derivatives (like VIXY and VIXM) and just focus on the gap changes between the indexes which gives me an idea of what is going on in the market and what contango/backwardation pressure is likely to exist next week.
Hope it is useful to you.
forex session - Opening-Range- JayyMy first try on anything forex. Let me know if it needs adjustment.
This is Opening Range for forex
Targets set at 127% , 162%, 200 %, 262 %, 362%, 423%, 685%, 1109% and 1794%
of the selected opening range. You can adjust targets as you like in the dialogue box
362%, 423%, 685%, 1109% and 1794% levels will not show unless selected in the dialogue box.
Check any one (only one) of the time periods to change the opening range period to suit.
New York opens at 8:00 am to 5:00 pm EST (EDT)
Tokyo opens at 7:00 pm to 4:00 am EST (EDT)
Sydney opens at 5:00 pm to 2:00 am EST (EDT)
London opens at 3:00 am to 12:00 noon EST (EDT)
Because the actual forex day starts at 5pm it is not possible to plot some time periods correctly
ie try 120 minutes on the New York session. (Although this is not a problem with the other sessions)
If you keep to an hour or less and use periods that divide evenly into an hour all will be fine. All periods will actually work but will start looking a little funny.
No such problem occurs if you just use 5pm est to 5 pm est. other sessions could be put in as options or hard wired in with a few lines of script changes
There is an option in the dialogue box to display fib targets within Opening Range itself.
In the far past I adapted some original work created by Chris Moody from a 7-07-2014 script - there have been multiple adaptations . The script layout/ structure remains similar and messages regarding targets achieved (lines 224 - 230) are from the original script. In the original Chris gave Special Thanks To "The Coding Genius Behind The Curtain" - so hat tip to both.
RSI Chebyshev Pro with Goldilocks Fractals - NR [NPR21]RSI Chebyshev Pro with Goldilocks Fractals - Non-Repaint
CHART INFORMATION
Instrument: /MNQ (Micro E-mini Nasdaq-100 Futures)
Timeframe: 2-minute
Indicator: RSI Chebyshev Pro with Goldilocks Fractals - NR
THE PROBLEM
Standard RSI is too choppy and noisy – it whipsaws all over the place in volatile markets like futures, giving false oversold/overbought signals that burn you on entries. I was sick of missing real reversals or getting stopped out on fakeouts. I wanted something smoother that still catches the big momentum shifts without lagging too much, plus actual market structure to make it more reliable for quick trades.
WHAT MAKES THIS UNIQUE
Unlike basic RSI indicators that use simple moving average smoothing, this combines several advanced techniques that aren't commonly found together:
1. Chebyshev Type I Filtering - Signal processing mathematics (not basic EMAs) that kills noise while keeping real swings sharp. Most RSI smoothing just blurs everything - this keeps responsiveness without the chop.
2. MAMA Adaptive Period - The moving average adapts to actual market cycles using the MESA algorithm, not fixed periods that lag in changing conditions.
3. RSI Pivot Fractals - These aren't price fractals slapped onto RSI. The fractals detect pivots directly on RSI values at extreme levels, with signals appearing back at the exact pivot bar (not current bar), showing you where the actual reversal happened.
4. True Non-Repainting Implementation - Signals appear delayed BUT locked at the historical pivot location forever. What you see in backtests is exactly what appeared live - no vanishing signals, no shifting.
5. All-in-One Integration - Instead of running 3-4 separate indicators (RSI + fractals + patterns + smoothing), everything works together in a single, optimized calculation with confluence built in.
This isn't just RSI with some Williams Fractals thrown on top - it's a complete rethink of how to identify high-probability RSI reversals using signal processing and adaptive algorithms.
ORIGIN & ENHANCEMENTS
Original Source: ChartPrime RSI Chebyshev indicator
Converted & Enhanced by: NPR21
What I Added:
✅ Converted to Pine Script v6 - Made this available to TradingView traders
✅ Goldilocks Fractals - RSI alone doesn't tell you about price structure. These fractals nail those "just right" pivot points where highs/lows confirm. I kept seeing RSI extremes that reversed hard when they lined up with fractals - this was the missing piece for confluence.
✅ 100% Non-Repainting - I've been burned by repainters. You'd backtest something, looks amazing, then live it vanishes or shifts. Lost real money on that. This is rock-solid: signals show delayed but once they're there, they're locked forever. Makes backtesting trustworthy.
✅ Candlestick Patterns - Engulfing, Morning Star, Evening Star detection for confluence
✅ Customizable Visuals - BUY/SELL labels, multiple display styles, full color/size control
✅ Complete Alert System - Get notified on all signal types
HOW IT WORKS
Chebyshev Filtering:
Like putting noise-canceling on your RSI – smooths out jittery ups and downs from random price spikes without flattening into useless lag. It's signal processing math that keeps important swings sharp while killing BS noise. Way better than simple EMA smoothing that blurs everything.
The Components:
Ultra-Smooth RSI - Chebyshev Type I filtering + adaptive MAMA algorithm
Goldilocks Fractals - Pivot detection confirmed after N bars (default 5)
Pattern Recognition - Detects Engulfing, Morning/Evening Star patterns
Visual Styles - Candle Trend (hollow green/solid red) or traditional candles
SIGNAL DELAY vs REPAINTING
✅ THIS HAS SIGNAL DELAY (GOOD) - NOT REPAINTING (BAD)
Signal Delay:
Signals appear after N bars (default 5 bar delay)
Once visible, NEVER disappears or moves
Perfect for backtesting - 100% reliable
What you see in history is what you'd see live
Why the Delay:
To confirm a pivot, we need to see price didn't go lower/higher in the next N bars. This confirmation makes signals reliable. The delay is the price for trustworthy signals.
Want faster? Drop Fractal Periods to 2-3 (more signals, less confirmation).
HOW I TRADE IT
My /MNQ Scalping (1-3 min charts):
LONG: BUY label appears (down fractal + maybe morning star/engulfing) → Check RSI crossing up from oversold (<30) → Confirm with volume → Long with stop below fractal low → Target 1-2R
SHORT: SELL label (up fractal + maybe evening star) → RSI from overbought → Short with stop above
Filter: Only longs in uptrends (watch the MA). Exit partials if momentum fades.
Best Timeframes: 1-5 min for futures scalping. Works on 15 min for swings but for pure scalping, stay under 5 min in high-vol sessions.
SETTINGS I USE
Standard Setup:
Length: 24, Smoothing: 3
Auto MA: ON, Multiplier: 1-2
Fractal Periods: 5 (good confirmation)
Choppy Days:
Smoothing to 5
Aggressive:
Fractal Periods to 3
Pro Tip: Pair with volume or price EMA. Love when fractal BUY + engulfing bull align. Use Candle Trend style. Test on demo first.
KEY SETTINGS
RSI: Length (24), Smoothing (3), Auto MA, Style (Candle/Candle Trend)
Fractals: Periods (5 = more reliable, 3 = faster/riskier), Label colors/sizes, Offsets
Alerts: All signals fire only on confirmed, non-repainting events
DISCLAIMERS
⚠️ Tool, not a complete system - use proper risk management
⚠️ Signals have delay for reliability - not for instant entries
⚠️ Best with price action, volume, other analysis
⚠️ Test on demo before live trading
Questions? Comment below!
NPR21
RSI Chebyshev Pro with Goldilocks Fractals - NR [NPR21]RSI Chebyshev Pro with Goldilocks Fractals - Non-Repaint
----------------------------------------------------------------------------------------------------------------------
CHART INFORMATION
Instrument: /MNQ (Micro E-mini Nasdaq-100 Futures)
Timeframe: 2-minute
Indicator: RSI Chebyshev Pro with Goldilocks Fractals - NR
----------------------------------------------------------------------------------------------------------------------
THE PROBLEM
Standard RSI is too choppy and noisy – it whipsaws all over the place in volatile markets like futures, giving false oversold/overbought signals that burn you on entries. I was sick of missing real reversals or getting stopped out on fakeouts. I wanted something smoother that still catches the big momentum shifts without lagging too much, plus actual market structure to make it more reliable for quick trades.
WHAT MAKES THIS UNIQUE
Unlike basic RSI indicators that use simple moving average smoothing, this combines several advanced techniques that aren't commonly found together:
1. Chebyshev Type I Filtering - Signal processing mathematics (not basic EMAs) that kills noise while keeping real swings sharp. Most RSI smoothing just blurs everything - this keeps responsiveness without the chop.
2. MAMA Adaptive Period - The moving average adapts to actual market cycles using the MESA algorithm, not fixed periods that lag in changing conditions.
3. RSI Pivot Fractals - These aren't price fractals slapped onto RSI. The fractals detect pivots directly on RSI values at extreme levels, with signals appearing back at the exact pivot bar (not current bar), showing you where the actual reversal happened.
4. True Non-Repainting Implementation - Signals appear delayed BUT locked at the historical pivot location forever. What you see in backtests is exactly what appeared live - no vanishing signals, no shifting.
5. All-in-One Integration - Instead of running 3-4 separate indicators (RSI + fractals + patterns + smoothing), everything works together in a single, optimized calculation with confluence built in.
This isn't just RSI with some Williams Fractals thrown on top - it's a complete rethink of how to identify high-probability RSI reversals using signal processing and adaptive algorithms.
ORIGIN & ENHANCEMENTS
Original Source: ChartPrime RSI Chebyshev indicator
Converted & Enhanced by: NPR21
What I Added:
✅ Converted to Pine Script v6 - Made this available to TradingView traders
✅ Goldilocks Fractals - RSI alone doesn't tell you about price structure. These fractals nail those "just right" pivot points where highs/lows confirm. I kept seeing RSI extremes that reversed hard when they lined up with fractals - this was the missing piece for confluence.
✅ 100% Non-Repainting - I've been burned by repainters. You'd backtest something, looks amazing, then live it vanishes or shifts. Lost real money on that. This is rock-solid: signals show delayed but once they're there, they're locked forever. Makes backtesting trustworthy.
✅ Candlestick Patterns - Engulfing, Morning Star, Evening Star detection for confluence
✅ Customizable Visuals - BUY/SELL labels, multiple display styles, full color/size control
✅ Complete Alert System - Get notified on all signal types
HOW IT WORKS
Chebyshev Filtering:
Like putting noise-canceling on your RSI – smooths out jittery ups and downs from random price spikes without flattening into useless lag. It's signal processing math that keeps important swings sharp while killing BS noise. Way better than simple EMA smoothing that blurs everything.
The Components:
Ultra-Smooth RSI - Chebyshev Type I filtering + adaptive MAMA algorithm
Goldilocks Fractals - Pivot detection confirmed after N bars (default 5)
Pattern Recognition - Detects Engulfing, Morning/Evening Star patterns
Visual Styles - Candle Trend (hollow green/solid red) or traditional candles
SIGNAL DELAY vs REPAINTING
✅ THIS HAS SIGNAL DELAY (GOOD) - NOT REPAINTING (BAD)
Signal Delay:
Signals appear after N bars (default 5 bar delay)
Once visible, NEVER disappears or moves
Perfect for backtesting - 100% reliable
What you see in history is what you'd see live
Why the Delay:
To confirm a pivot, we need to see price didn't go lower/higher in the next N bars. This confirmation makes signals reliable. The delay is the price for trustworthy signals.
Want faster? Drop Fractal Periods to 2-3 (more signals, less confirmation).
HOW I TRADE IT
My /MNQ Scalping (1-3 min charts):
LONG: BUY label appears (down fractal + maybe morning star/engulfing) → Check RSI crossing up from oversold (<30) → Confirm with volume → Long with stop below fractal low → Target 1-2R
SHORT: SELL label (up fractal + maybe evening star) → RSI from overbought → Short with stop above
Filter: Only longs in uptrends (watch the MA). Exit partials if momentum fades.
Best Timeframes: 1-5 min for futures scalping. Works on 15 min for swings but for pure scalping, stay under 5 min in high-vol sessions.
SETTINGS I USE
Standard Setup:
Length: 24, Smoothing: 3
Auto MA: ON, Multiplier: 1-2
Fractal Periods: 5 (good confirmation)
Choppy Days:
Smoothing to 5
Aggressive:
Fractal Periods to 3
Pro Tip: Pair with volume or price EMA. Love when fractal BUY + engulfing bull align. Use Candle Trend style. Test on demo first.
KEY SETTINGS
RSI: Length (24), Smoothing (3), Auto MA, Style (Candle/Candle Trend)
Fractals: Periods (5 = more reliable, 3 = faster/riskier), Label colors/sizes, Offsets
Alerts: All signals fire only on confirmed, non-repainting events
DISCLAIMERS
⚠️ Tool, not a complete system - use proper risk management
⚠️ Signals have delay for reliability - not for instant entries
⚠️ Best with price action, volume, other analysis
⚠️ Test on demo before live trading
Questions? Comment below!
NPR21
RSI Chebyshev Pro with Goldilocks Fractals - NR [NPR21]RSI Chebyshev Pro with Goldilocks Fractals - Non-Repaint
==================================================================================
**CHART INFORMATION**
The example chart shown displays:
- Instrument: /MNQ (Micro E-mini Nasdaq-100 Futures)
- Timeframe: 2-minute
- Indicator: RSI Chebyshev Pro with Goldilocks Fractals - NR
==================================================================================
═════════════════════════════════════════════════════════════
THE PROBLEM
Standard RSI is too choppy and noisy – it whipsaws all over the place in volatile markets like futures, giving false oversold/overbought signals that burn you on entries. I was sick of missing real reversals or getting stopped out on fakeouts. I wanted something smoother that still catches the big momentum shifts without lagging too much, plus actual market structure to make it more reliable for quick trades.
═════════════════════════════════════════════════════════════
WHAT MAKES THIS UNIQUE
Unlike basic RSI indicators that use simple moving average smoothing, this combines several advanced techniques that aren't commonly found together:
1. Chebyshev Type I Filtering - Signal processing mathematics (not basic EMAs) that kills noise while keeping real swings sharp. Most RSI smoothing just blurs everything - this keeps responsiveness without the chop.
2. MAMA Adaptive Period - The moving average adapts to actual market cycles using the MESA algorithm, not fixed periods that lag in changing conditions.
3. RSI Pivot Fractals - These aren't price fractals slapped onto RSI. The fractals detect pivots directly on RSI values at extreme levels, with signals appearing back at the exact pivot bar (not current bar), showing you where the actual reversal happened.
4. True Non-Repainting Implementation - Signals appear delayed BUT locked at the historical pivot location forever. What you see in backtests is exactly what appeared live - no vanishing signals, no shifting.
5. All-in-One Integration - Instead of running 3-4 separate indicators (RSI + fractals + patterns + smoothing), everything works together in a single, optimized calculation with confluence built in.
This isn't just RSI with some Williams Fractals thrown on top - it's a complete rethink of how to identify high-probability RSI reversals using signal processing and adaptive algorithms.
═════════════════════════════════════════════════════════════
ORIGIN & ENHANCEMENTS
Original Source: ChartPrime RSI Chebyshev indicator
Converted & Enhanced by: NPR21
What I Added:
✅ Converted to Pine Script v6 - Made this available to TradingView traders
✅ Goldilocks Fractals - RSI alone doesn't tell you about price structure. These fractals nail those "just right" pivot points where highs/lows confirm. I kept seeing RSI extremes that reversed hard when they lined up with fractals - this was the missing piece for confluence.
✅ 100% Non-Repainting - I've been burned by repainters. You'd backtest something, looks amazing, then live it vanishes or shifts. Lost real money on that. This is rock-solid: signals show delayed but once they're there, they're locked forever. Makes backtesting trustworthy.
✅ Candlestick Patterns - Engulfing, Morning Star, Evening Star detection for confluence
✅ Customizable Visuals - BUY/SELL labels, multiple display styles, full color/size control
✅ Complete Alert System - Get notified on all signal types
═════════════════════════════════════════════════════════════
HOW IT WORKS
Chebyshev Filtering:
Like putting noise-canceling on your RSI – smooths out jittery ups and downs from random price spikes without flattening into useless lag. It's signal processing math that keeps important swings sharp while killing BS noise. Way better than simple EMA smoothing that blurs everything.
The Components:
Ultra-Smooth RSI - Chebyshev Type I filtering + adaptive MAMA algorithm
Goldilocks Fractals - Pivot detection confirmed after N bars (default 5)
Pattern Recognition - Detects Engulfing, Morning/Evening Star patterns
Visual Styles - Candle Trend (hollow green/solid red) or traditional candles
═════════════════════════════════════════════════════════════
SIGNAL DELAY vs REPAINTING
✅ THIS HAS SIGNAL DELAY (GOOD) - NOT REPAINTING (BAD)
Signal Delay:
Signals appear after N bars (default 5 bar delay)
Once visible, NEVER disappears or moves
Perfect for backtesting - 100% reliable
What you see in history is what you'd see live
Why the Delay:
To confirm a pivot, we need to see price didn't go lower/higher in the next N bars. This confirmation makes signals reliable. The delay is the price for trustworthy signals.
Want faster? Drop Fractal Periods to 2-3 (more signals, less confirmation).
════════════════════════════════════════════════════════════
HOW I TRADE IT
My /MNQ Scalping (1-3 min charts):
LONG: BUY label appears (down fractal + maybe morning star/engulfing) → Check RSI crossing up from oversold (<30) → Confirm with volume → Long with stop below fractal low → Target 1-2R
SHORT: SELL label (up fractal + maybe evening star) → RSI from overbought → Short with stop above
Filter: Only longs in uptrends (watch the MA). Exit partials if momentum fades.
Best Timeframes: 1-5 min for futures scalping. Works on 15 min for swings but for pure scalping, stay under 5 min in high-vol sessions.
═════════════════════════════════════════════════════════════
SETTINGS I USE
Standard Setup:
Length: 24, Smoothing: 3
Auto MA: ON, Multiplier: 1-2
Fractal Periods: 5 (good confirmation)
Choppy Days: Smoothing to 5
Aggressive: Fractal Periods to 3
Pro Tip: Pair with volume or price EMA. Love when fractal BUY + engulfing bull align. Use Candle Trend style. Test on demo first.
═════════════════════════════════════════════════════════════
KEY SETTINGS
RSI: Length (24), Smoothing (3), Auto MA, Style (Candle/Candle Trend)
Fractals: Periods (5 = more reliable, 3 = faster/riskier), Label colors/sizes, Offsets
Alerts: All signals fire only on confirmed, non-repainting events
═════════════════════════════════════════════════════════════
DISCLAIMERS
⚠️ Tool, not a complete system - use proper risk management
⚠️ Signals have delay for reliability - not for instant entries
⚠️ Best with price action, volume, other analysis
⚠️ Test on demo before live trading
═════════════════════════════════════════════════════════════
Questions? Comment below!
NPR21
Midnight Open Levels by haze!This indicator automatically plots the midnight open prices for both the New York (00:00 EST) and London (00:00 GMT) trading sessions. These levels are widely recognized in institutional trading frameworks as significant reference points for intraday price action.
What Are Midnight Open Levels?
Midnight open levels represent the price at which each major trading session begins at 00:00 local time. Institutional traders and algorithmic systems often reference these levels when making trading decisions, which can create zones of increased liquidity and potential price reactions.
This indicator is provided for educational purposes. No indicator guarantees profitable trades. Always practice proper risk management, use appropriate position sizing, and conduct your own analysis before making trading decisions.
Evidenzia Data Specifica DinamicaSpecific Date Highlighter
Descrizione (Italiano)
Questo indicatore semplice ma estremamente efficace permette di evidenziare graficamente un'intera giornata specifica selezionata dall'utente. È lo strumento ideale per chi ha bisogno di analizzare il comportamento del prezzo durante eventi macroeconomici passati, date di earnings, o particolari sessioni storiche.
Caratteristiche principali:
Selettore Calendario Intuitivo: Grazie all'input di tipo time, puoi selezionare la data esatta tramite un calendario pop-up senza dover inserire manualmente numeri per giorno, mese e anno.
Compatibilità Multi-Timeframe: L'indicatore funziona su qualsiasi timeframe. Se sei su grafici intraday (1m, 5m, 1h), colorerà lo sfondo di tutte le candele appartenenti a quel giorno. Su grafici Daily, evidenzierà la singola candela selezionata.
Colore Personalizzabile: Puoi scegliere il colore dello sfondo e la sua opacità direttamente dalle impostazioni per adattarlo al tuo tema (Light o Dark).
Data Dinamica: Lo script è progettato per riconoscere automaticamente la data odierna come punto di partenza, facilitando l'analisi rapida dell'ultima sessione.
Casi d'uso:
Backtesting visivo: Evidenzia i giorni di rilascio dei dati CPI o decisioni FOMC per studiare la volatilità.
Journaling: Segna i giorni in cui hai effettuato trade importanti per ritrovarli facilmente nello storico.
Analisi Ciclica: Identifica rapidamente date specifiche in cui si sono verificati minimi o massimi storici.
Description (English)
This lightweight and effective tool allows you to highlight a specific full day on your chart. It is perfect for traders who need to visually isolate price action during macroeconomic events, earnings dates, or key historical sessions.
Key Features:
Calendar Picker: Easily select your target date using a built-in calendar input.
MTF Ready: Works seamlessly across all timeframes. On intraday charts, it highlights every bar within the 24-hour period. On daily charts, it highlights the specific daily candle.
Fully Customizable: Change the background color and transparency to match your chart layout.
Smart Default: The script is optimized to handle time logic correctly, ensuring the highlight starts exactly at 00:00 and ends at 23:59.
How to use: Go to settings, click on "Select Date", pick your day from the calendar, and the chart will instantly move the focus to that specific session.
Open Range BreakoutOpen Range Breakout is a volatility harvesting tool designed to exploit directional expansion following major market opens. It isolates price action during initial liquidity injections to project institutional-grade zones that define a session's structural bias.
Core Methodology
The script uses a time-anchored engine to map critical supply and demand boundaries:
Anchor Identification: The algorithm captures the absolute High and Low within a user-defined window at the start of Tokyo, London, or New York sessions.
Structural Projection: It generates a Neutrality Box. A breach via candle close signals the transition from consolidation to expansion.
Mathematical Risk Modeling: Upon breakout, it calculates a 3:1 Risk-Reward framework based on fixed percentage volatility.
Session Dynamics
The system is optimized for the global liquidity cycle:
Session 1 (Asia): Maps early-day consolidation and range-bound liquidity.
Session 2 (Europe): Captures the London Move to identify the trend.
Session 3 (US): Analyzes high-volume New York opens for maximum momentum.
Key Features
Dynamic Price Mitigation: TP/SL zones stop extending the moment price touches the target or invalidation level to keep charts clean.
Volatility-Adjusted Levels: Stop Loss parameters are normalized to price percentage for consistency across Indices, Forex, or Crypto.
Minimalist Interface: Professional aesthetic with high-contrast visual cues for instant scannability.
Use Cases
Momentum Trading: Identifying the Origin of the Move post-open.
Mean Reversion: Recognizing failed breakouts when price returns inside the range.
Quantitative Backtesting: Benchmarking 3.0 RR targets across different session anchors.
Elder AutoEnvelope 1m/5mOverview
This script is an advanced implementation of Dr. Alexander Elder’s AutoEnvelope, specifically optimized for 1-minute (1m) and 5-minute (5m) low-timeframe trading.
The logic treats the market as a "manic-depressive" entity:
Center Line (26 EMA): Represents the fair value consensus.
Fast Line (13 EMA): Captures short-term price momentum.
Envelopes (Bands): Represent the limits of price "sanity." Under normal conditions, 95% of price action should remain within these bands.
Key Features
Powered by Pine Script V6: Built on the latest engine for maximum precision and performance.
Real-time Coverage Tracker: A dashboard in the top-right corner displays the percentage of price bars contained within the bands over the lookback period. The goal is to adjust the Multiplier until coverage is ~95%.
Dual Smoothing: To combat high-frequency noise on 1m/5m charts, this script applies a secondary smoothing layer to the channel width, preventing the "jagged" lines found in standard indicators.
Recommended Settings
Lookback: Defaulted to 300. On a 1m chart, this represents 5 hours of data, providing a much more robust "normal" range than the standard 100-period setting.
Multiplier: Usually ranges between 2.0 and 3.5 depending on the asset's volatility. Tune this until the Coverage Panel shows ~95%.
SmoothLen: Defaulted to 20. Increase this value for even smoother, more "parallel" bands during high-noise sessions.
Practical Trading Advice
Take Profit Zones: In an uptrend, treat the Upper Band as a primary target. When price pierces the band and closes back inside, it’s often the climax of the move.
Mean Reversion: When price touches the Lower Band while significantly stretched away from the yellow Center Line, look for a bounce back to the value area, especially if the Purple Fast Line begins to flatten.
Trend Filtering:
Price above Fast Line (Purple) + Upward slope: Bullish bias. Only look for Longs or Profit Taking.
Price below Fast Line (Purple) + Downward slope: Bearish bias. Only look for Shorts or Covering.
Asset Calibration: When switching assets (e.g., Gold to BTC), always fine-tune the Multiplier. The bands are only statistically valid when the Coverage Panel stays between 94% and 96%.
指标简介
本脚本是基于亚历山大·爱尔德博士(Dr. Alexander Elder)著名的“自动包络线”(AutoEnvelope)理论开发的进阶版本,特别针对 1分钟(1m)和 5分钟(5m) 等短周期高频交易进行了优化。
该指标的核心逻辑是将市场视为一个“躁郁症患者”:
中心线 (26 EMA):代表市场的平均价值认同。
快线 (13 EMA):代表短期价格动能。
包络线 (Bands):代表价格波动的极端边界(95% 的价格应运行在通道内)。
核心功能
V6 引擎驱动:采用最新的 Pine Script V6 编写,计算更精准,内存占用更低。
实时覆盖率统计:右上角实时显示过去 300 根 K 线中有多少比例落在通道内。目标是手动调整倍数(Multiplier)使该数值维持在 95% 左右。
双重平滑处理:针对短线噪音,对通道宽度进行了二次平滑,避免了传统指标在 1 分钟图上常见的“锯齿状”变形。
参数设置建议
Lookback (回溯周期):默认 300。在 1m 图上代表过去 5 小时,能提供比默认 100 周期更稳定的边界。
Multiplier (偏离倍数):根据不同品种调整(通常在 2.0 - 3.5)。请观察右上角面板,当覆盖率接近 95% 时,该倍数最为准确。
SmoothLen (平滑系数):默认 20。如果觉得轨道太乱,可调高此值。
实际交易建议
波段止盈点:在上升趋势中,当价格刺破上轨且 K 线实体收回上轨下方时,是绝佳的多头平仓位。
均值回归:当价格偏离中心线触碰下轨,且快线(紫色)开始走平时,预示即将反弹回中心线。
趋势过滤:
价格在快线(紫色)上方且快线斜率向上:只做多或平多,不逆势抄顶。
价格在快线(紫色)下方且快线斜率向下:只做空或平空。
覆盖率校准:切换交易品种(如从黄金切换到比特币)后,务必微调 Multiplier,确保覆盖率处于 94%-96% 之间,此时的边界才具有统计学意义。






















