Multi Horizontal Lines 540Draws horizontal lines depends on condition of regular price, if 10000 then increment is 540, otherwise increment by 54
Lines
Multi Horizontal LinesAbility to plot multi price lines, go to settings and put price and increment of lines.
Enjoy
[RD] LCS - line channels (basic) v3 - [republish]==================================================================
July 18 2019 - LCS - line channels (basic) by RootDuk
Version : v3 - read the notes
==================================================================
Easy script to draw channels based on ie. GANN using the following
input params
- ibback : barsback to search for high and low
- ffactor : factor to up/downscale the lines
- oextend : extend lines, left, right, both, none
- bshowline : show horizontal lines yes/no
- bsshowdown : show diag down lines yes/no
- bsshowup : show diag up lines yes/no
- bshowindm : show index marker, where is you current ibback
===================================================================
Notes
===================================================================
When you use this code, pls let me know where and how you used it
as iam always curious what some can do with it. Thanks!
===================================================================
Updates
===================================================================
v1
v2 - July 17 2019
- Removed support wallets from source code. I think the source
- has been deleted because of this, find no other clue.
v3 - July 18 2019
- Republish
[RD] high / low lines pv4 v1==================================================================
July 7 2019 - high / low lines pv4 v1 - by RootDuk
==================================================================
Easy script to draw some lines on the input variable barsback.
You can extend the lines on the sides: left, right, both or none.
With the show variables (bools) you can show or hide the lines
Lines: high to high, low to low, high to low or low to high
Easy way to find support / resistance based on the past with
extended lines. Cheers and enjoy
===================================================================
Notes
===================================================================
Hope TV (pinescript) will get color inputs for line or a type color so we can
easily create inputs for colors for lines. Now its static. If someone knows
another way, pls let me know, i'll integrate it
===================================================================
Updates
===================================================================
Non so far v1
Simple LinesIntroduction
Making lines is great in technical analysis since it can highlights principal movements and make the analysis of the price easier when using certain methodologies (Elliott Waves, patterns).
However most of the indicators making lines (Zig-Zag, simple linear regression) are non causal (repaint), this is the challenge i tried to overcome, making an indicator capable of making lines in a smart way (able to follow price without loosing a linear approach) and with the least lag possible, i inspired myself from the behaviour of the renko when using a small brick size. This indicator does not repaint .
The code is short and i hope, understandable for all of you, making lines is not a difficult task and its important to know that when a problem appear complex it does not mean that the code used to solve this problem must be complex. Lets see the indicator in details.
The indicator
The indicator have 4 parameters, the length parameter who control the length of lines, the emphasis parameter who control the stability and also the ability to make lines closer to the price (thus minimizing the sum of squares) , the mult parameter which is similar to emphasis and a point option that we will discuss later.
When emphasis and mult are both equal to 1 the indicator will sometimes draw a perfect line, however this line will try to follow the price and thus can create a noisy result.
This is where emphasis and mult will correct this behaviour. The emphasis parameter give a more periodic look as well as some control to the lines but can also destroy them.
This should not happen with mult , this parameter also give more predictability to the lines. Overall it correct the drawbacks of the parameters combinations mentioned earlier.
Its also possible to mix both the emphasis and mult parameter, but take into account that when both are equals the result consist of less reactive lengthy lines with low accuracy. Its better to only use one of them and let the other stay to 1.
Point Option
The indicator can sometimes have a weird look, appearing almost flat or just dont appearing at all. When such thing happen use the point option.
XPDUSD without point option.
with point option :
Time Frame Problem and Its Fix
When using higher time-frames the result of the indicator can appear different, in general the higher the time frame the lengthier are the lines. In order to fix this you can use decimals in the length parameter
length and mult both equal to 5.5, emphasis cant use decimals.
Conclusion
I have highlighted a simple way to make use of the small renko box size method in order to return reactive lines without making the indicator repaint. However Its ability to be close to the price as well as being always super reactive is not a guarantee.
For any suggestion/help feel free to pm me, i would be happy to help you :)
trendline function - JD!EXPERIMENTAL!
As TV doesn't provide a function to draw lines between points, I wrote a function to do this in one my own indicators.
The function itself however can be applied/modified for different use cases, eg. drawing trendlines.
In this (proof of concept) example I used it to draw lines based on past high/low pivot points.
The inputs required:
* an INPUT FUNCTION (in this form, its designed to work with functions that have occasional values and na-values between them, it then connects the non-zero values to form a line)
* a BOOL (to indicate if you want to draw only the rising or falling lines)
* a DELAY (in this case this is the lookback period for the pivot-points function, this is to compensate the calculation of the past and realtime points)
The function returns:
* the function to draw the extension from the BASE-LINE to the current time (here this is the connection of the last pivot-point to the current point to bridge the gap of the lookback period, this is NOT REALTIME!)
* the function to draw the extension for the current time (here this is the continuation of the line until a new pivot-point is valid, this is DRAWN IN REALTIME!!)
* the color of the lines (in this case the lines are only colored (lime or fuchsia) if they either go up or down, else they are invisible, this is to clean up the invalid lines)
these output functions can then simply be plotted using the 'plot' function.
JD.
EFI 13 8study(title="EFI", shorttitle="EFI")
XLen1 = input(13, minval=1)
XLen2 = input(8, minval=1)
hline(0, color=gray, linestyle=line)
xValue = volume * (close - close )
xSMA1 = ema(xValue, XLen1)
xSMA2 = ema(xValue, XLen2)
plot(xSMA1, style = columns, color=aqua, title="SlowAvg")
plot(xSMA2, color=white, title="FastAvg")
log 3EMAlogarithmic exponential moving average
plots 3 lines instead of 1
default is 50,100,200
use standard scale instead of log, for this to work properly.
BTC tip jar: 1Mv1s7nLaTsRoLai5WXEGg8doisXuiPUXy
ETH tip jar: 0x6113DDD23D0D5aCad3d1f8640A8A571E9Cb86cB8
LTC tip jar: LYvyoqTSWxa22TQw3E7818xy4AfYNi6xcm
BCH tip jar: 1GC7oZ7MhLkamKCDdZFnUfV21SKWq84VdY
Sweetspot Gold RN - by JustUncleLThis is an alternate version of "Sweetspot Gold R4" that does not use sublevels. Removing the sublevels allows more efficient use of the plots (TV script has a limit of 64 plot calls).
This works well for all currency pairs I've tested, most commodities, and most stocks.
The indicator plots the so called "round price levels" or "00" levels. For example, 1.4000, 1.4400, 1.4500.
It automatically calculates the levels for each chart time frame. Optionally you can manually select main level size (in pips)
Use this indicator as a guidance to a better mapping of Support/Resistance levels on the chart. Next time you draw Support/Resistance lines, if they coincide with round price levels, you have got a excellent S/R level to work with!
Sweetspot Gold R4-22 - by JustUncleLThis upgrade I have attempted to improve the Automatic levels calculation and better automatic levels selections. It should now work better with exotic currencies, indices, commodities, and stocks.
The indicator plots the so called "round price levels" or "00" levels, which end on 00 and 50: for example, 1.4000, 1.4400, 1.4450. It automatically calculates the levels for based on your charts time frame. Alternatively you can manually select main level size (in pips) and/or the number of sub-levels (0, 1, 2, 3, 9). Generally speaking, the program tries to keep to 3 Digit "00" rounding for currencies and non-stocks, and 2 Digit "00" rounding for Stocks.
Use this indicator as a guidance to a better mapping of Support/Resistance levels on the chart. Next time you draw Support/Resistance lines, if they coincide with round price levels, especially "00", you have got a excellent S/R level to work with!
[RS]Fractal Auto Gann LinesEXPERIMENTAL:
GANN lines projection based on zigzag tops/bottoms, use at your own risk.
[RS]Average Advance and Decline Lines V0Method to draw linear regression lines from average price advance&decline range