RicardoSantos

[RS]Monthly Dynamic Range Levels (Fibonaci) V0

2086 3 584
Monthly fibonaci range analysis and system
Remove from Favorite Scripts Add to Favorite Scripts
study("[RS]Monthly Dynamic Range Levels (Fibonaci) V0", overlay=true)
Optional_TimeFrame = input('M')

M_HIGH = security(tickerid, Optional_TimeFrame, high)
M_OPEN = security(tickerid, Optional_TimeFrame, open)
M_LOW = security(tickerid, Optional_TimeFrame, low)

H_RANGE = M_HIGH-M_OPEN
L_RANGE = M_OPEN-M_LOW

H_236 = M_HIGH - H_RANGE * 0.236
H_382 = M_HIGH - H_RANGE * 0.382
H_500 = M_HIGH - H_RANGE * 0.500
H_618 = M_HIGH - H_RANGE * 0.618
H_764 = M_HIGH - H_RANGE * 0.764

L_236 = M_LOW + L_RANGE * 0.236
L_382 = M_LOW + L_RANGE * 0.382
L_500 = M_LOW + L_RANGE * 0.500
L_618 = M_LOW + L_RANGE * 0.618
L_764 = M_LOW + L_RANGE * 0.764

plot(M_HIGH, color=M_HIGH != M_HIGH[1] ?na:black, style=line, linewidth=1)

plot(H_236, color=H_236 != H_236[1] ?na:gray, style=line, linewidth=1)
plot(H_382, color=H_382 != H_382[1] ?na:black, style=line, linewidth=1)
plot(H_500, color=H_500 != H_500[1] ?na:red, style=line, linewidth=1)
plot(H_618, color=H_618 != H_618[1] ?na:black, style=line, linewidth=1)
plot(H_764, color=H_764 != H_764[1] ?na:gray, style=line, linewidth=1)

plot(M_OPEN, color=M_OPEN != M_OPEN[1] ?na:blue, style=line, linewidth=2)

plot(L_236, color=L_236 != L_236[1] ?na:gray, style=line, linewidth=1)
plot(L_382, color=L_382 != L_382[1] ?na:black, style=line, linewidth=1)
plot(L_500, color=L_500 != L_500[1] ?na:red, style=line, linewidth=1)
plot(L_618, color=L_618 != L_618[1] ?na:black, style=line, linewidth=1)
plot(L_764, color=L_764 != L_764[1] ?na:gray, style=line, linewidth=1)

plot(M_LOW, color=M_LOW != M_LOW[1] ?na:black, style=line, linewidth=1)

SHOW_MA = input(false)
MA_SRC = input(hlc3)
MA_LENGTH = input(21)

_MA = ema(MA_SRC, MA_LENGTH)
plot(not SHOW_MA ? na : _MA, color=teal, linewidth=2)

SHOW_SIGNALS = input(true)

BUYX(_F) => cross(_F, MA_SRC) and rising(_MA, 1)
SELX(_F) => cross(_F, MA_SRC) and falling(_MA, 1)

SEL_SIGNAL = SELX(H_236) or SELX(H_382) or SELX(H_500) or SELX(H_618) or SELX(H_764) or
        SELX(L_236) or SELX(L_382) or SELX(L_500) or SELX(L_618) or SELX(H_764)

BUY_SIGNAL = BUYX(H_236) or BUYX(H_382) or BUYX(H_500) or BUYX(H_618) or BUYX(H_764) or
        BUYX(L_236) or BUYX(L_382) or BUYX(L_500) or BUYX(L_618) or BUYX(H_764)

plotshape(not SHOW_SIGNALS ? na : SEL_SIGNAL ? M_HIGH : na, style=shape.labeldown, location=location.absolute, text='-', color=maroon, textcolor=white, transp=0)
plotshape(not SHOW_SIGNALS ? na : BUY_SIGNAL ? M_LOW : na, style=shape.labelup, location=location.absolute, text='+', color=green, textcolor=white, transp=0)
Would be possible to make so it shows which percentage each line is? Ex: so at the 50% line it says 50%
Reply
How does it work?
Reply
RicardoSantos PRO nathanael.hartley
it plots a grid from open to extremes(high/low) and when price crosses a fib line it triggers a signal...
experimental and untested use with discretion... ;)
Reply
EN English
EN English (UK)
EN English (IN)
DE Deutsch
FR Français
ES Español
IT Italiano
PL Polski
TR Türkçe
RU Русский
PT Português
ID Bahasa Indonesia
MS Bahasa Melayu
TH ภาษาไทย
VI Tiếng Việt
JA 日本語
KO 한국어
ZH 简体中文
ZH 繁體中文
Home Stock Screener Forex Signal Finder Cryptocurrency Signal Finder Economic Calendar How It Works Chart Features House Rules Moderators Website & Broker Solutions Widgets Stock Charting Library Feature Request Blog & News FAQ Help & Wiki Twitter
Profile Profile Settings Account and Billing My Support Tickets Contact Support Ideas Published Followers Following Private Messages Chat Sign Out