TradingView
BillionaireLau
2021년 12월 29일 오후 5시 26분

Universal logarithmic growth curves, with support and resistance 

Bitcoin / U.S. dollarBitstamp

설명

Logarithmic regression is used to model data where growth or decay accelerates rapidly at first and then slows over time. This model is for the long term series data (such as 10 years time span).

The user can consider entering the market when the price below 25% or 5% confidence and consider take profit when the price goes above 75% or 95% confidence line.

This script is:
- Designed to be usable in all tickers. (not only for bitcoin now!)
- Logarithmic regression and shows support-resistance level
- Shape of lines are all linear adjustable
- Height difference of levels and zones are customizable
- Support and resistance levels are highlighted

Input panel:
- Steps of drawing: Won't change it unless there are display problems.
- Resistance, support, other level color: self-explanatory.
- Stdev multipliers: A constant variable to adjust regression boundaries.
- Fib level N: Base on the relative position of top line and base line. If you don't want all fib levels, you might set all fib levels = 0.5.
- Linear lift up: vertically lift up the whole set of lines. By linear multiplication.
- Curvature constant: It is the base value of the exponential transform before converting it back to the chart and plotting it. A bigger base value will make a more upward curvy line.



FAQ:
Q: How to use it?
A: Click "Fx" in your chart then search this script to get it into your chart. Then right click the price axis, then select "Logarithmic" scale to show the curves probably.

Q: Why release this script?
A: - This script is intended to to fix the current issues of bitcoins growth curve script, and to provide a better version of the logarithmic curve, which is not only for bitcoin , but for all kinds of tickers.
- In the public library there is a hardcoded logarithmic growth curve by @quantadelic . But unfortunately that curve was hardcoded by his manual inputs, which makes the curve stop updating its value since 2019 the date he publish that code. Many users of that script love using it but they realize it was stop updating, many users out there based on @quantadelic version of "bitcoin logarithmic growth curves" and they tried their best to update the coordinates with their own hardcode input values. Eventually, a lot of redundant hardcoded "Bitcoin growth curve" scripts was born in the public library. Which is not a good thing.

Q: What about looking at the regression result with a log scale price axis?
A: You can use this script that I published in a year ago. This script display the result in a log scale price axis.
tradingview.com/script/GaJ9GTCq-Logarithmic-regression/

릴리즈 노트

layout updated

릴리즈 노트

Layout updated

릴리즈 노트

One more example application: YINN entry in 31-12-2021 at fib-level close to zero by 8.3$ entry price in 31-12-2021.

릴리즈 노트

Minor bug fixes

릴리즈 노트

Layout update and minor fixes.

릴리즈 노트

Some users report error "Study error: Bar Index value of the 'x2' argument (-121.000000) in 'line.set_x***()' is too far from the current bar index." occurs. Pinescript currently don't support plotting any lines where bar index is bigger than they suppose to provide i.e. 5000, but they also made some tickers freely provide bar index larger than that amount.

New feature associated with this issue:
1) "Automatic" method: The script would extend its range by its maximum and
2) "Manual" method: The user can customized their range (suggest < 5000) as a way to avoid the error.

But I still suggest users to grasp as much bar_index as they can, because logarithmic curves are long-term analysis. So the second way to resolve that issue is switch the chart to "Weekly". So the logarithmic curves would show up normally in the right place.
코멘트
Trendoscope
Thanks for your contribution to tradingview community.
BillionaireLau
ab_yf
What is the most effective way to use this, in your opinion?
bigmacblk
Awsome man, love your work... thanks
Nisargadatta01
Dude, this is awesome. Thank you!
BillionaireLau
@Nisargadatta01, I'm glad to hear that. Thank you!
zagaEbaya
I get a Study error...Bar Index value of the 'x2' argument (-121.000000) in 'line.set_x***()' is too far from the current bar index. Try using 'time' instead.
Maybe a problem with my screen settings idk
BillionaireLau
@zagaEbaya, Thanks for the feedback. I just updated the script. Please have a look on the release note above.
Please tell me more when you faced other problems.
There are a handful of things I observed in this script and I also want to add it into the script. Once I have collected several issues by the users I will give it a big update.
zagaEbaya
@BillionaireLau, Weekly and daily charts are working, I was hoping to test it on a 30min chart too,,but for now I'll just observe the day charts and see how i can make it work for me,,thank you.
BillionaireLau
@zagaEbaya , I just tested, you could play it on any timeframe chart, in case you have chosen "manual" method in the input panel.
My opinion is, as I have written in the first two lines in the description, it is designed for longer timespan (eg: months or years).
더보기