Volume AccumulationA simple tool that accumulates the trading volume of an instrument for a specified period of time.
Available modes:
Minutely
Hourly
Session
Daily
Monthly
Quarterly
Yearly
8-period
Minkowski Distance Factor Adaptive Period MACDHi, this script comes from the idea that Ricardo Santos' Minkovski Distance Function is transferred to the period as a factor.
Minkowski distance is used as a percentage factor with the help of Relative Strength Index function.
Minkowski Distance Function Script :
And thus an adaptive MACD was created.
This script can give much better results in more optimized larger periods.
I leave the decision to determine the periods and weights.
I used the weights of 9,12,26 and periods created with multiplied by factor.
Regards.
intraday trading perioddisplay the intraday trading period (08:30 - 15:00) on chart with high transparent white background.
you can edit the time period by yourself in the pine editor mode.
Enhanced Instantaneous Cycle Period - Dr. John EhlersThis is my first public release of detector code entitled "Enhanced Instantaneous Cycle Period" for PSv4.0 I built many months ago. Be forewarned, this is not an indicator, this is a detector to be used by ADVANCED developers to build futuristic indicators in Pine. The origins of this script come from a document by Dr. John Ehlers entitled "SIGNAL ANALYSIS CONCEPTS". You may find this using the NSA's reverse search engine "goggles", as I call it. John Ehlers' MESA used this measurement to establish the data window for analysis for MESA Cycle computations. So... does any developer wish to emulate MESA Cycle now??
I decided to take instantaneous cycle period to another level of novel attainability in this public release of source code with the following methods, if you are curious how I ENHANCED it. Firstly I reduced the delay of accurate measurement from bar_index==0 by quite a few bars closer to IPO. Secondarily, I provided a limit of 6 for a minimum instantaneous cycle period. At bar_index==0, it would provide a period of 0 wrecking many algorithms from the start. I also increased the instantaneous cycle period's maximum value to 80 from 50, providing a window of 6-80 for the instantaneous cycle period value window limits. Thirdly, I replaced the internal EMA with another algorithm. It reduces the lag while extracting a floating point number, for algorithms that will accept that, compared to a sluggish ordinary EMA return. You will see the excessive EMA delay with adding plot(ema(ICP,7)) as it was originally designed. Lastly it's in one simple function for reusability in a nice little package comprising of less than 40 lines of code. I hope I explained that adequately enough and gave you the reader a glimpse of the "Power of Pine" combined with ingenuity.
Be forewarned again, that most of Pine's built-in functions will not accept a floating-point number or dynamic integers for the "length" of it's calculation. You will have to emulate the built-in functions by creating Pine based custom functions, and I assure you, this is very possible in many cases, but not all without array support. You may use int(ICP) to extract an integer from the smoothICP return variable, which may be favorable compared to the choppiness/ringing if ICP alone.
This is commonly what my dense intricate code looks like behind the veil. If you are wondering why there is barely any notation, that's because the notation is in the variable naming and this is intended primarily for ADVANCED developers too. It does contain lines of code that explore techniques in Pine that may be applicable in other Pine projects for those learning or wishing to excel with Pine.
Showcased in the chart below is my free to use "Enhanced Schaff Trend Cycle Indicator", having a common appeal to TV users frequently. If you do have any questions or comments regarding this indicator, I will consider your inquiries, thoughts, and ideas presented below in the comments section, when time provides it. As always, "Like" it if you simply just like it with a proper thumbs up, and also return to my scripts list occasionally for additional postings. Have a profitable future everyone!
NOTICE: Copy pasting bandits who may be having nefarious thoughts, DO NOT attempt this, because this may violate Tradingview's terms, conditions and/or house rules. "WE" are always watching the TV community vigilantly for mischievous behaviors and actions that exploit well intended authors for the purpose of increasing brownie points in reputation scores. Hiding behind a "protected" wall may not protect you from investigation and account penalization by TV staff. Be respectful, and don't just throw an ma() in there branding it as "your" gizmo. Fair enough? Alrighty then... I firmly believe in "innovating" future state-of-the-art indicators, and please contact me if you wish to do so.
Enhanced Autocorrelation Periodogram RasterChart - EhlersFirstly, this is NOT an indicator. It's an advanced cycle period detector for advanced developers OR scripts providing a "Period Source" they may have developed that can utilize this detector. Be forewarned! I would only recommend this for advanced developers, not novice. If you are up to the challenge of manually altering period adjustments on the daily chart of an indicator by hand in real time, you may still obtain this indicator after negotiating a proper request for access, but I will say this, it is NOT suitable for all indicators.
Understand all of the above aforementioned? Proceed...
For those of you wondering how I did it without Pine support for arrays, I had to emulate them, totaling over 600+ lines of code. This was a formidable task to achieve. This may be the hardest task I have ever accomplished, as of yet, in Pine.
Now, on to the Description...
This is my enhanced and heavily* modified version of Dr. John Ehlers' autocorellation periodogram for detecting dominant cycles(frequencies) in an asset using Pine Script version 4.0. The original concept comes from chapter 8 of his book "Cycle Analytics for Traders" and may also be found in TASC magazine in the September 2016 issue. I did heavily modify the original computations for the purpose of providing the "maximum" amount of adjustability there is to possibly offer, but left the original settings intact. I also provided an assortment of vibrant color changing techniques to choose from for anyone who may have vision impairments. This also displays that color scheming is VERY possible in Pine ...if only I could get "chart.theme" for auto-detection.
I once again would personally like to thank the talented individuals at TV for providing a platform that embraces an initial free membership, which I first obtained myself, for individuals like me to freely code in Pine with mathemagical ideas and mental wizardry, creating ultimately, inventions like this eye candy display above.
Features List Includes:
"Source" Selection
Color schemes (displayed above)
Transparency for the heat map to reduce or intensify color brightness ( Thank you TV! For this feature...)
The detected dominant cycle can be 'Sourced' by another specially** modified script providing an integer, float, or a rounded float.
Resolution enhancement has 3 settings
Smoother period control
Highpass period control
Pearson correlation period control
Minimal Power Threshold Tweak(Experimental***)
Adjustment for the smoothing coefficients of the Fourier Transforms(Experimental!)
This is not a freely available indicator, FYI. To witness my Pine poetry in action, properly negotiated requests for unlimited access, per indicator, may ONLY be obtained by direct contact with me using TV's "Private Chats" or by "Message" in my member name above. The comments section below is solely just for commenting and other remarks, ideas, compliments, etc... If you do have any questions or comments regarding this indicator, I will consider your inquiries, thoughts, and ideas presented below in the comments section, when time provides it. As always, "Like" it if you simply just like it, and also return to my scripts list occasionally for additional postings. Have a profitable future everyone!
* This has additional features/tweaks not included in the original.
** Many Pine built-in functions WILL NOT support the use of this detector if 'Sourced' to control a period setting. You have to totally rewrite those built-in Pine functions in Pine script. Yes, it is very possible! BUT ...in many cases, not all.
*** This "modification" reduces large spikes in the detected dominant cycle period with increased adjustment. Increasing this value may reduce dominant cycle spikes around 0.3-ish
In-Phase & Quadrature IFMThis indicator provides a continuous measurement of a securities' dominant cycle period, based on Ehlers ever-impressive reports and analysis tools.
This method uses in-phase and quadrature analysis, making use of the imaginary domain. This method is prone to favor longer periods and can
allow noise to greatly affect the end result.
>What does that even mean?
Essentially, you get a real-time (low lag) plot of the cycle period in bars. If the I-Q IFM reads "16" then you can expect the distance between swing highs and swing lows to be approx. 16 bars.
>How is this useful?
When you throw an RSI or MACD on your chart, you can now set the "Period" or "Length" value with confidence.
Knowing the dominant cycle period tells you that price reversal will occur around these intervals.
>Extending.
The better way to use this tool is by extending the script into any indicators that use a length or period that is set manually.
Simply use the "len" variable in your custom script to replace your input values.
Now you have a way to adaptively set the period value, using signal processing theory instead of just intuition ;)
PM if you have questions.
Cosine IFM [Ehlers]This indicator provides a continuous measurement of a securities' dominant cycle period, based on Ehlers ever-impressive reports and analysis tools.
>What does that even mean?
Essentially, you get a real-time (low lag) plot of the cycle period in bars. If the COS IFM reads "16" then you can expect the distance between swing highs and swing lows to be approx. 16 bars.
>How is this useful?
When you throw an RSI or MACD on your chart, you can now set the "Period" or "Length" value with confidence.
Knowing the dominant cycle period tells you that price reversal will occur around these intervals.
>Extending.
The better way to use this tool is by extending the script into any indicators that use a length or period that is set manually.
Simply use the "len" variable in your custom script to replace your input values.
Now you have a way to adaptively set the period value, using signal processing theory instead of just intuition ;)
PM if you have questions.
Percentage Change FunctionThis is little code snippet can be copied and pasted into your own strategies and indicators to easily calculate some interesting percentage change levels within a given lookback period.
The function will return:
The price change from the start to the end of the period
The price change from the start of the period to the highest point within the period
The price change from the start of the period to the lowest point within the period
It was originally intended to be used in conjunction with other scripts to assist with decision making. However, it doesn't look too bad as an indicator and so plots have been added.
For more information regarding the code, some commentary and free tutorials, you can visit the Bactest-Rookies (.com) website.
Ghost TrendUse ghosted charts from multiple exchanges to visualize global market trends for your trading pair BEFORE the trend comes to your exchange. Use Ghost Averaging to find what Bitcoin is ACTUALLY doing across up to four exchanges, by averaging all four exchanges into a single ghost. As for the name, Ghost Trend just sounded way cooler than Arbitrage Helper!
Hone your skills and you may even find yourself able to avoid crashes moments BEFORE they happen, or able buy right BEFORE a take-off. Ghosts sometimes show moves earlier than the exchange you're using. But be careful, sometimes ghosts are nasty little deceivers 8o
Instructions:
First time ghosting? Start out with a 1 minute Bitcoin chart on Coinbase ( ), then check out the Ghost Trend settings.
Start small, pick just one alternate exchange (say Bitfinex ) and play with the Ghosted Open/High/Low/Close settings. Certain combinations will display bars by default, others will display plotted lines. Make it work for you.
Next, pick a second exchange and you'll see a second ghost. Now comes the fun part. Click "Average Ghosted Pairs". Now you're looking at the two averaged together. You can even average Coinbase back into the Ghosted Average if you want. Add up to four, and most importantly, have fun.
DON'T FORGET TO SET THE CORRECT CHART RESOLUTION!!! Everything goes haywire if you mismatch Ghost Trend's resolution with your current chart.
Lots of fun to be had on the 1 minute chart, but it's especially useful to use Ghost Averaging with Open and Close unchecked and High and Low checked, when on greater resolution charts. ;) Happy arbitraging!
If you'd like to incorporate Ghost Trend into your script, you know where to find me.
~jdhadwin
C320up MPC EMA 5 by Chart ResolutionC320up "MPC" EMA 5 by Chart Resolution
- This is a custom version of our C320up EMA by Chart Resolution.
This version has 5 EMA’s and is easier to quickly switch chart resolutions, this time using only 2 chart periods.
Why have filtered chart resolutions?
Some EMA’s don’t tend to give a useful indication at a given chart resolution, so any resolution not selected will not have the EMA lines appear on the screen.
Default resolutions are “240” Minutes (4 Hour), and “D” (1 Day).
With these settings the EMA lines will only appear on the 4 Hour and Daily charts.
Default EMA’s are 20, 50, 100, 200, and 1200.
Why 1200 you may ask. 1200 on the 4 Hour chart is equivalent to 200 on the Daily chart.
You can change these inputs to suit your requirements.
The first input is used to manually type in the chart resolution, as the TV built in drop downs don’t have all of the chart resolutions, 240 Minutes (4 Hour) for example.
If you don’t want them all to show on the screen, you can un-check them in the Style tab in settings.
Check out our scripts page for more indicators. (Including our Bear Power Indicator)
Any questions, just leave a comment.
If you want more control over the chart resolutions, try using this one:
"C320up EMA by Chart Resolution"
C320up EMA by Chart ResolutionC320up EMA by Chart Resolution
- You may only want your EMA’s to appear on specific chart resolutions.
Use this indicator to select up to four resolutions and four EMA’s.
Sometimes a certain EMA (Exponential Moving Average) doesn’t give a good indication on a smaller time frame or vice versa, so you can customise these to suit.
Default settings are “240” Minutes for all EMA’s to appear.
Default EMA’s are 20, 50, 100, and 200.
To change the resolution, type in one of these examples:
15 = 15 Minutes, 60 = 1 Hour, 240 = 4 Hours, D = Day, W = Week, M = Month, 2M = 2 Months, etc.
You could have just the one EMA appear on multiple time frames, or have 2 appear on 2 time frames, etc.
Check out our scripts page for more indicators.
Any questions, just leave a comment.
CMYK RYTHM ◊ Introduction
This script makes use of a sliding matrix, to search the highest/lowest point in the slider, it then counts the amount of times it was high/low, giving the distance from a previous high/low.
Every High/low are granted values, being a lower value for shorted periods, and a larger value for Longer periods.
This reveals the different period lengths of active frequencies.
Doing this with different slider lenghts would result in measuring with different mean period lenghts.
◊ Origin
From my dream last night.
This is a part of Project XIAM.
◊ Theoretical Approach
Philosophy β :: Rythmic
Searching for the period lenght of several frequencys at once.
◊ Usage
This is an alalythical tool, to be used for Automatically adjusting settings on Indicators that presume a period length for calculation.
Calculations are based on Past values, and no reversal measures or fail-safes are applied, so it will only be useful during a continuation of trend.
◊ Features
Matrix Calculation of Lowest/Highest points in a sliding series with Steady Length.
In the future Several slider lenghts will be applied to search for Frequencies of different magnitudes.
Lenght between TOPS, DIPS , and an SMA that smoothens this.
BIAS Is TOP to DIP Minus DIP to TOP, to uncover Bullish/Bearish index of market movements.
◊ Community
CMYK :: discord.gg
AUTOVIEW :: discordapp.com
TRADINGVIEW UNOFFICIAL :: discord.gg
Custom Time ranges
Description:
This script colours the background of any time range you specify, including weekend periods.
It can be useful for spotting patterns on Bitcoin (recurring times of buying or selling).
Checkboxes to switch on and off. Inputs to specify time and day of week.
Monday = 2
Tuesday = 3
Wednesday = 4
Thursday = 5
Friday = 6
Saturday = 7
Sunday = 1
Example 1:
1500-1800:2
This will colour the background between 3pm and 6pm on Mondays.
Example 2:
0000-0600:247
This will colour the background between midnight and 6am on Mondays, Wednesdays, and Saturdays.
Any questions you may have, please leave in comments below and I'll respond when I have time.
Pinks MultiRSIAn indicator that displays whether RSI is oversold, undersold, or neutral, on several timeframes:
15m, 30m, 45m, 1h, 2h, 3h, 4h, 5h, 6h, 12h, 18h, 1D.
If RSI for a specific interval is overbought, the bars for that interval turn red (for "sell"). If it is oversold, it turns green (for "buy"). The RSI length, oversold level, and overbought level are tuneable.
The bottom row of coloumns is 15m RSI, top row is 1D RSI. It is recommended to use log scale on this indicator. The bar height is proportional to the interval it cover.
ADX and RSI ComboThis indicator combines two separate Simple RSI indicators so you can show different periods together, as well as an ADX indicator with DI+ and DI-. I prefer to use one indicator to show the whole thing, instead of stacking the individual indicators.
Bactest Period MarkerSimple script that will mark backtest periods (if you have to run backtests in multiple parts, like on CryptoTrader )
Time zoneRegular script to allocate the specified time range within a day.
TradingView in time is specified by UTC. I Moscow time (GMT +3) and the time specified in the script Default 1:00 - 13:00 Moscow time equal 09:00 - 21:00 ie -8 Hours from the Moscow time (-7 in summer).
========== ==========
Обычный скрипт для выделения указанного диапазона времени внутри дня.
Время в TradingView указывается по UTC. У меня московское время (GMT +3) и время указанное в скрипте по умолчания 01:00 - 13:00 по московскому времени равняется 09:00 - 21:00 , т.е. -8 часов от московского времени (-7 в летнее время).
Kaufman Adaptive Moving Average (day)The KAMA will not change when the interval changes from day to something like 5 minutes or 30 minutes. Allows for more precise trading with the same indicator on a different interval.