87 2 9
point system index , for test only
Remove from Favorite Scripts Add to Favorite Scripts
study(title="[RS]Point System Index", shorttitle="[RS]PSI")
range = 50
length1 = 6
length2 = 12
length3 = 24
pm = 2
pip = 0.0001 * close
margin = pip*pm

track =
//isUp
    close - open > margin * 10 ? 10 : 
    close - open > margin * 8 ? 8 :
    close - open > margin * 6 ? 6 :
    close - open > margin * 4 ? 4 :
    close - open > margin * 2 ? 2 :
    close - open > margin * 1 ? 1 :
//isDown
    open - close > margin * 10 ? -10 : 
    open - close > margin * 8 ? -8 :
    open - close > margin * 6 ? -6 :
    open - close > margin * 4 ? -4 :
    open - close > margin * 2 ? -2 :
    open - close > margin * 1 ? -1 : 0

track1 =
//weight size of wick down on up candles
    close > open and open - low > margin * 10 ? -5 : 
    close > open and open - low > margin * 8 ? -4 :
    close > open and open - low > margin * 6 ? -3 :
    close > open and open - low > margin * 4 ? -2 :
    close > open and open - low > margin * 2 ? -1 :
    close > open and open - low > margin * 1 ? -0 :
//weight size of wick up on down candles
    open < close and high - close > margin * 10 ? 5 : 
    open < close and high - close > margin * 8 ? 4 :
    open < close and high - close > margin * 6 ? 3 :
    open < close and high - close > margin * 4 ? 2 :
    open < close and high - close > margin * 2 ? 1 :
    open < close and high - close > margin * 1 ? 0 : 0

tr1 = round(sum(track+track1, range))
ma1 = wma(round(tr1), length1)
ma2 = wma(round(ma1), length2)
ma3 = wma(round(ma2), length3)

c1 = ma1 > tr1 ? red : green
c2 = ma2 > ma1 ? red : green
c3 = ma3 > ma2 ? red : green

plot(tr1, color=green)
plot(ma1, color=c1)
plot(ma2, color=c2)
plot(ma3, color=c3)
hline(0)
vdubus PRO
2 years ago
I'm impressed :)
Reply
vdubus PRO
2 years ago
snapshot
+1 Reply
Ideas Scripts Chart
United States
United Kingdom
India
España
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Billing Sign Out