GreatStockMark

Upside Reversals

GreatStockMark 업데이트됨   
Upside reversal is noticed when a stock first dips below the prior week's low, then rallies in heavy trade to close either with a gain or with a much-reduced loss. Upside reversal can be identified with following condition:

A stock falls in heavy volume but bounces back, ending up for the day or week
OR
A stock falls in heavy volume but at least it finishes in the upper 60% of its trading range for the day or week

Upside reversal can be applied on day or week but if it is on weekly, it is a strong indication that institutions may be pumping money as they think stock is a bargain. This script is the approximate conversion of Richard Moglen's TC2000 scripts in TradingView. Search YouTube for his video on 'Upside Reversal'

This indicator, evaluates following conditions and print the arrow down label with percentage of reversal
Stoc(1,1) should be higher than 60%;
AND today's close is above 60% range;
AND today's low is lesser than yesterday;
AND Stoc(5,2,1) is lesser than 65

You can change inputs from Stoc(5,2,1) to Stoc(10,4,1) based on your need.

NOTE:
1) I still see some false positives so be aware of it.
2) It is absolutely possible to have an Upside reversal on down trend also. Please look for confirmation following day on the trend before act on it.
3) Volume level is not validated in the indicator, so you need to include it in the chart and check it.
4) This is still an experimental script & published for educational purpose only
릴리즈 노트:
UPDATE: Added new switch to turn off the labels & to select background and text colors for label.

Here is the complete scirpt:

//@version=4
study("Upside Reversals", overlay = true, max_labels_count=100)
//Input parameters. This can be changed from 5,2,1 to 10,4,2
kPeriod = input(5, minval=1, title="Upside Reversal - K Period")
dPeriod = input(2, title="Upside Reversal - D Period")
smoothK = input(1, title="Upside Reversal - smooth K")
showLabels = input(true, title="Show Labels", type = input.bool)
color c_indicator = input(color.purple, "Indicator Color", type = input.color)
color c_labeltext = input(color.white, "Label Text", type = input.color)

// truncate() truncates a given number to a certain number of decimals
truncate(number, decimals) =>
factor = pow(10, decimals)
int(number * factor) / factor

//Get the stoc K value
k = sma(stoch(close, high, low, kPeriod), smoothK)
stoc5_2_1 = sma(k, dPeriod)

// Get the stoc(1,1)
stoc1_1 = sma(stoch(close, high, low, 1), 1)

//Daily range close calculation
val = (close-low)/(high-low)

//today's low is lesser than yesterday's low then lowfactor is -ve
lowfactor = low - low
//Text to print the % of reversal to range
revPercent = truncate((val*100),2)
Textval = tostring(revPercent)+"%"

//Evaluate the conditions and print the label
//stoc1_1 should be higher than 60%;
// AND today's close is above 60% range;
// AND today's low is lesser than yesterday;
// AND stoc5_2_1 is lesser than 65 then display the Upside Reversal Label
if (stoc1_1 > 60 and val > 0.6 and lowfactor < 0 and stoc5_2_1 < 65)
if showLabels
label1 = label.new(bar_index, low-2, text=Textval, style=label.style_labelup, color=c_indicator)
label.set_textcolor(label1,c_labeltext)
else
label1 = label.new(bar_index, low-2, style=label.style_labelup, color=c_indicator)
label.set_textcolor(label1,c_labeltext)

보호된 스크립트입니다
이 스크립트는 클로즈 소스로 게시되며 자유롭게 사용할 수 있습니다. 당신은 스크립트를 차트에 사용하기 위해 그것을 즐겨찾기 할 수 있습니다. 소스 코드는 보거나 수정할 수 없습니다.
면책사항

이 정보와 게시물은 TradingView에서 제공하거나 보증하는 금융, 투자, 거래 또는 기타 유형의 조언이나 권고 사항을 의미하거나 구성하지 않습니다. 자세한 내용은 이용 약관을 참고하세요.

차트에 이 스크립트를 사용하시겠습니까?