CapnOscar

MyTrend

908 views
104
908 1
Choose timeframe for pivots ...Play with it you can find this useful
Remove from Favorite Scripts Add to Favorite Scripts
//Coded by CapnOscar on 16.04.2015 - Say Thanks?
study(title="MyTrend", shorttitle="MyTrend", overlay=true)

picktf = input(title="Pick TimeFrame", type=resolution, defval="30")


previous_close = security(tickerid, picktf,close[1])
previous_open = security(tickerid, picktf,open[1])
cur_open = security(tickerid, picktf,open)
previous_high = security(tickerid, picktf,high[1])
previous_low = security(tickerid, picktf,low[1])
cur_high = security(tickerid, picktf,high)
cur_low = security(tickerid, picktf,low)




D = (cur_high - cur_low)
Q = (previous_high - previous_low)
P = (previous_high + previous_low + previous_close) / 3
R1 = (2*P)-previous_low
S1 = (2*P)-previous_high
R2 = P+(previous_high - previous_low)
S2 = P-(previous_high - previous_low)


rsic = close > P ? green : close < P ? red : orange

pv = plot(P, color=rsic, linewidth=3)
plr1 = plot(R1, color=silver)
plr2 = plot(R2, color=gray)
pls1 = plot(S1, color=silver)
pls2 = plot(S2, color=gray)

GoodJob Captain
Reply
Home Stock Screener Forex Screener Crypto Screener Economic Calendar How It Works Chart Features Pricing House Rules Moderators Website & Broker Solutions Widgets Charting Solutions Help Center Feature Request Blog & News FAQ Wiki Twitter
Profile Profile Settings Account and Billing TradingView Coins My Support Tickets Help Center Ideas Published Followers Following Private Messages Chat Sign Out