CapnOscar

CapnsSurfer

This is a simple RMA Trend that may help you decide for SL or TP. Similar to CapnsBands this uses Donchian Channels.. but remember. Your Trade Your Money

Howto Read Capns Surfer - I will write more later
First of all this is NOT a BUY or SELL indicator. However with this you can define sweet spots for ENTRIES, or TRAILING STOPS and recognize the trend.

Sweetspots
Mã nguồn mở

Với tinh thần TradingView, tác giả của tập lệnh này đã xuất bản nó dưới dạng mã nguồn mở, vì vậy các nhà giao dịch có thể hiểu và xác minh nó. Chúc mừng tác giả! Bạn có thể sử dụng mã này miễn phí, nhưng việc sử dụng lại mã này trong một ấn phẩm chịu sự điều chỉnh của Nội quy nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Thông báo miễn trừ trách nhiệm

Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?
//@author CapnOscar 
study(shorttitle="CapnsSurfer", title="CapnsSurfer", overlay=true)

//Define Variables 
uprsi = 51
dorsi = 49

//MajorTrend
major = close, majlen = input(84, minval=1, title="MajorTrend RSI" )
majup = rma(max(change(major), 0), majlen)
majdo = rma(-min(change(major), 0), majlen)
majtrend = majdo == 0 ? 100 : majup == 0 ? 0 : 100 - (100 / (1 + majup / majdo))
//ColorMajorRSI
majcol = majtrend > uprsi ? lime : majtrend < dorsi ? red : yellow

//Define Donchian Bollinger
back = input(1, minval=0)
price = close
range = input(2, minval=0)
lower = lowest(majlen/range)
upper = highest(majlen/range)
basis = avg(upper[back], lower[back])
trend = rma(price, majlen)
l = plot(lower[back], color=silver)
u = plot(upper[back], color=silver)
MajTr = plot(trend[back], linewidth= 4, color=majcol)
fill(u, MajTr, color=blue, transp=95)
fill(MajTr, l, color=red, transp=95)

//Define Mas
hiout = rma(high, 3)
loout = rma(low, 3)
//Define 20Mas
hiout2 = rma(high, 20)
loout2 = rma(low, 20)

//ColorTrueMa
truemacol = hiout > trend ? green : loout < trend ? red : yellow
truema = hiout > trend ? loout : loout < trend ? hiout : avg(hiout,loout)
truMa= plot(truema, color=truemacol, linewidth= 1, title="TinyTrend")

//ColorTrueMa2
truemacol2 = hiout2 > trend ? green : loout2 < trend ? red : yellow
truema2 = hiout2 > trend ? loout2 : loout2 < trend ? hiout2 : avg(hiout2,loout2)
truMa2= plot(truema2, color=truemacol2, linewidth= 1, title="TinyTrend")

fill(truMa, MajTr, color=aqua, transp=90)
fill(truMa2, MajTr, color=blue, transp=90)