답변완료
종목검색 요청 합니다
input : Periods(10);
input : Multiplier(3.0);
input : changeATR(true);
input : showsignals(true);
input : highlighting(true);
var : src(0),alpha(0),atr1(0),atr2(0),atrv(0);
var : up(0),up1(0),dn(0),dn1(0);
var : trend(0),tx(0);
src = (h+l)/2;
alpha = 1/Periods;
atr1 = iff(IsNan(atr1[1]) == true,ma(TrueRange, Periods), alpha * TrueRange + (1 - alpha) * iff(IsNan(atr1[1])==true,0,atr1[1]));
atr2 = ma(TrueRange, Periods);
atrv = iff(changeATR ==true,atr1, atr2);
up = src-(Multiplier*atrv);
up1 = iff(isnan(up[1])==true,up,up[1]);
up = iff(close[1] > up1 , max(up,up1), up);
dn = src+(Multiplier*atrv);
dn1 = iff(isnan(dn[1])==true,dn,dn[1]);
dn = iff(close[1] < dn1 , min(dn, dn1) , dn);
trend = 1;
trend = iff(isnan(trend[1])==true,trend,trend[1]);
trend = iff(trend == -1 and close > dn1 , 1 , iff(trend == 1 and close < up1 , -1 , trend));
if trend == 1 Then
{
plot1(up,"Up Trend",green);
NoPlot(2);
}
Else
{
NoPlot(1);
plot2(dn,"Down Trend",Red);
}
if trend == 1 and trend[1] == -1 Then
{
tx = Text_New(sDate,sTime,up,"●");
Text_SetColor(tx,Green);
Text_SetStyle(tx,2,2);
}
if trend == -1 and trend[1] == 1 Then
{
tx = Text_New(sDate,sTime,dn,"●");
Text_SetColor(tx,Red);
Text_SetStyle(tx,2,2);
}
이거 지표 쓰고 있는데
여기서 업트랜드로 하방 돌파 했을때 종목검색과 검색표시 부탁드립니다
2024-05-12
752
글번호 179398
종목검색
답변완료
수식 변환 부탁 드립니다.
안녕하세요!
다음 파인스크립트 수식을 예스로 변환 부탁드립니다.
감사합니다.
source = close
useCurrentRes = input(true, title="Use Current Chart Resolution?")
resCustom = input(title="Use Different Timeframe? Uncheck Box Above", type=resolution, defval="60")
smd = input(true, title="Show MacD & Signal Line? Also Turn Off Dots Below")
sd = input(true, title="Show Dots When MacD Crosses Signal Line?")
sh = input(true, title="Show Histogram?")
macd_colorChange = input(true,title="Change MacD Line Color-Signal Line Cross?")
hist_colorChange = input(true,title="MacD Histogram 4 Colors?")
res = useCurrentRes ? period : resCustom
fastLength = input(12, minval=1), slowLength=input(26,minval=1)
signalLength=input(9,minval=1)
fastMA = ema(source, fastLength)
slowMA = ema(source, slowLength)
macd = fastMA - slowMA
signal = sma(macd, signalLength)
hist = macd - signal
outMacD = security(tickerid, res, macd)
outSignal = security(tickerid, res, signal)
outHist = security(tickerid, res, hist)
histA_IsUp = outHist > outHist[1] and outHist > 0
histA_IsDown = outHist < outHist[1] and outHist > 0
histB_IsDown = outHist < outHist[1] and outHist <= 0
histB_IsUp = outHist > outHist[1] and outHist <= 0
//MacD Color Definitions
macd_IsAbove = outMacD >= outSignal
macd_IsBelow = outMacD < outSignal
plot_color = hist_colorChange ? histA_IsUp ? aqua : histA_IsDown ? blue : histB_IsDown ? red : histB_IsUp ? maroon :yellow :gray
macd_color = macd_colorChange ? macd_IsAbove ? lime : red : red
signal_color = macd_colorChange ? macd_IsAbove ? yellow : yellow : lime
circleYPosition = outSignal
plot(smd and outMacD ? outMacD : na, title="MACD", color=macd_color, linewidth=4)
plot(smd and outSignal ? outSignal : na, title="Signal Line", color=signal_color, style=line ,linewidth=2)
plot(sh and outHist ? outHist : na, title="Histogram", color=plot_color, style=histogram, linewidth=4)
plot(sd and cross(outMacD, outSignal) ? circleYPosition : na, title="Cross", style=circles, linewidth=4, color=macd_color)
hline(0, '0 Line', linestyle=solid, linewidth=2, color=white)
2024-05-12
781
글번호 179397
지표
답변완료
수식 질문합니다.
안녕하세요.
조건1:
O[3]>C[3] and O[2]>C[2] and O[1]>C[1] and O<C and
V[2]*1.1<V[1] and V[1]<V
조건1을 만족한 후
조건2:
If
H[11]==Max(H[1],H[2],H[3],H[4],H[5],H[6],H[7],H[8],H[9],H[10],H[11])
Then Var1=H[11];
Else
{
if C[1]<Var1 and CrossUp(C,var1) Then
Find(1);
}
조건2를 처음 만족하는 종목.(조건1보다 조건2의 값이 더 큼)
감사합니다.
2024-05-12
717
글번호 179396
종목검색
답변완료
수식 질문합니다.
안녕하세요.
var: OO(0);
OO=Min(O,C);
If Min(OO[3],OO[2],OO[1],OO) >= Max(L[3],L[2],L[1],L) Then
find(1);
위 수식 조건을 만족한 이후 Min(OO[3],OO[2],OO[1],OO)선과 Max(L[3],L[2],L[1],L)선을 동시에 첫번째 종가이탈한 뒤 다시 동시에 종가돌파한 종목.
감사합니다.
2024-05-12
739
글번호 179394
종목검색
답변완료
질문 요청 드립니다.
* 항상 많은 도움에 고맙습니다.
<질문1> 아래 부분에서 굵기를 다르게 할수 있나요?
즉 Black은 굵기8 Magenta 는 굵기4 로 할수 있나요?
Plot81(Var28,IFF(Var28 < Var28[10],Black,Magenta),Def,0);
1
input : P1(5),P2(10),P3(20),P4(30),P5(40),P6(50),P7(60),P8(120),P9(240);
var1 = ma(c,P1);
var2 = ma(c,P2);
var3 = ma(c,P3);
var4 = ma(c,P4);
var5 = ma(c,P5);
var6 = ma(c,P6);
var7 = ma(c,P7);
var8 = ma(c,P8);
var9 = ma(c,P9);
Condition1 = var1 > Var2 and Var2 > Var3 and Var3 > Var4 and Var4 > Var5 and Var5 > Var6 and Var6 > Var7 and Var7 < Var8 and Var8 > Var9;
Condition2 = var1 < Var2 and Var2 < Var3 and Var3 < Var4 and Var4 < Var5 and Var5 < Var6 and Var6 < Var7 and Var7 < Var8 and Var8 < Var9;
if Condition1 == true and Condition1 == False Then
PlaySound("C:₩예스트레이더₩data₩Sound₩alert.wav");
if Condition2 == true and Condition2 == False Then
PlaySound("C:₩예스트레이더₩data₩Sound₩stop.wav");
2
input : P1(5),P2(10),P3(20),P4(30),P5(40),P6(50),P7(60),P8(120),P9(240);
var1 = ma(c,P1);
var2 = ma(c,P2);
var3 = ma(c,P3);
var4 = ma(c,P4);
var5 = ma(c,P5);
var6 = ma(c,P6);
var7 = ma(c,P7);
var8 = ma(c,P8);
var9 = ma(c,P9);
Condition1 = var1 > Var2 and Var2 > Var3 and Var3 > Var4 and Var4 > Var5 and Var5 > Var6 and Var6 > Var7 and Var7 < Var8 and Var8 > Var9;
Condition2 = var1 < Var2 and Var2 < Var3 and Var3 < Var4 and Var4 < Var5 and Var5 < Var6 and Var6 < Var7 and Var7 < Var8 and Var8 < Var9;
if Condition1 == true Then
PlaySound("C:₩예스트레이더₩data₩Sound₩alert.wav");
if Condition2 == true Then
PlaySound("C:₩예스트레이더₩data₩Sound₩stop.wav");
즐거운 하루되세요
2024-10-05
813
글번호 179393
지표