TradingView
dgtrd
9. Jul. 2021 09:42

Distance Oscillator - Support and Resistance by DGT 

Bitcoin / TetherUSBinance

Beschreibung



Prices high above the Moving Average (MA) or low below it are likely to be remedied in the future by a reverse price movement as stated in the article by Denis Alajbeg, Zoran Bubas and Dina Vasic published in International Journal of Economics, Commerce and Management

This study is the third variant that aims to present this idea, and the output of the study is presented as lines that serve as possible support and resistance levels in the future.

1st variant of the idea is presented as an centered oscillator, link to Price Distance to its MA Study, within its description you may find more about the idea and some statistical observations. Also some derivatives with MACD-X, More Than MACD and P-MACD




2nd variant of the idea are presented as colored triangle line (Volatility Colored Price/MA Line), using the same calculation methods and presented in the bottom of price chart.
Link to studies where it is included : Colored Directional Movement and Bollinger Band's Cloud, SuperTrendRange and [url=tradingview.com/script/1iUeEIHq-Pivot-Points-KrisWaters-vX-by-DGT/
] Pivot Points [KrisWaters] vX




3rd variant (this study) as stated earlier aims to present the same idea as support and resistance levels.

Options
The users can adjust source and length of the moving average that is used as base for the distance oscillator
Signal triggering options includes length for the deviation bands, multiplier as well as smoothing of the oscillator
Line customization settings

Additionally an alert can be configured to be warned earlier to watch out for probable pullbacks or reversals


Technical details for whom interested

Calculating the price distance to the MA results in a centered oscillator lets call it Distance Oscillator (quite similar to the RSI), as shown in the blow chart



Unlike RSI, oscillations with the distance oscillator are not limited within a specific range, hence identifying overbought and oversold is not as straight forward as it is with RSI. To determine overbought and oversold levels, standard deviation of distance oscillator is calculated and bands generated with the same approach applied with Bollinger Bands.

Once we have the threshold bands then crossing those bands we may assume as important levels and draw a line, if oscillator values keeps above the threshold bands (deviation bands) the logic behind the code will update the line drawing accordingly.



To reduce noise a smoothing can be applied



Alerts :




Please note that the implementation applied here can be applied to any oscillator such as RSI, Stochastic, MFI etc even Volume (if bear candle volumes are multiplied by -1)

Disclaimer:
Trading success is all about following your trading strategy and the indicators should fit within your trading strategy, and not to be traded upon solely

The script is for informational and educational purposes only. Use of the script does not constitute professional and/or financial advice. You alone have the sole responsibility of evaluating the script output and risks associated with the use of the script. In exchange for using the script, you agree not to hold dgtrd TradingView user liable for any possible claim for damages arising from any decision you make based on use of the script
Kommentare
ICEKI
This is an another great job dude, also appreciated dgtrd for posting several pictures for the details explain
This is awesome; keep it up my friend; thank you <3
dgtrd
thank You very much @ICEKI
balipour
Price isn't mean reverting. For a moving average to equal the value of current price as price moves in a geometric Brownian motion is unsurprising. Also, the value of a moving avergae being equal to the current price doesn't indicate anything about the probabilites of future movements in price. Those probabilites only depend on the distribution of returns and their cumulative distribution function. Which is why "S/R" don't exist and the visual appearance of one doesn't mean anything because the next tick is still 50-50. Unless it's an area in price where there are inefficiencies and therefore some degree of predictability and those will show up in the form of autocorrelation in returns. We believe the community will actually benefit more if the base level of understanding for certain rudimentary but fundamental facts about price and returns was higher.
dgtrd
@balipour, thank you very much for your valuable comment, it is much appreciated

Gann used angles, squares and other geometric constructions in his forecasting methods

Elliott proposes that the seemingly chaotic behavior of the different financial markets isn’t actually chaotic. In fact the markets moves in predictable, repetitive cycles or waves and can be measured and forecast using Fibonacci numbers

Andrew W. Lo and Archie Craig MacKinlay in their book “A Non-Random Walk Down Wall Street” stated that the price reflects all currently known information about an asset and may move in trends and that the study of past prices can be used to forecast future price direction

Many believe that emotions are the main driving force behind the shifts of financial markets - this commonly observed behavior of securities prices is sharply at odds with random walk. By gauging greed and fear in the market, investors can better formulate long and short portfolio stances

Many short-term traders rely exclusively on price action and the formations and trends extrapolated from it to make trading decisions

Nobody appears to know whether Fibonacci tools/Market Geometry work because markets exhibit some form of natural pattern/geometric shapes or because many investors use Fibonacci ratios / Market Geometry to predict price movements, making them a self-fulfilling prophecy.

My trading approach (btw, I am not an algo trader) relies on the idea that the market is geometric and cyclical in nature, and I do enjoy a lot synergies between statistics and geometry as Linear Regression channels
chrisjk
Hello DGT

The indicator P/MA S&R is not updating the lines on chart. Is required to refresh the chart to see the indicator updated
Can you fix it?

Thanks
RodrigoKazuma
As always, great job!
dgtrd
thnak You @RodrigoKazuma, glad to hear this
chartmojo
Great job as usual. This would work really well intraday off of vwap and or developing 50% of days range or "midpoint". MA's are incidental in comparison.
chartmojo
@chartmojo, The nature of vwap and 50% is such that there is more gravity. Vwap and 50% range will usually be close during the session and eventually pull poc to them. More traders trade to them and away from them. ,The more they confluence the more gravity, traders, orders, targets, entries, exits,stops. MA's are more "averages" and there is always some ma on price on some time frame.
tickersmob
True distance from moving avarge is calculated by %, other thrn that is misleading
Mehr