예스스탁
예스스탁 답변
2025-06-23 14:48:48
안녕하세요
예스스탁입니다.
input : length1(24);
var : src(0),a(0),p(0),b(0),clr(0),tx(0);
src = (h+l)/2;
a = wma((2 * wma(src,length1 / 2)) - wma(src, length1), round(sqrt(length1),0));
p = length1/2;
b = wma(wma(close,p/3)*3 - wma(close,p/2) - wma(close,p),p);
clr = iff(b > a , lime , red);
plot1(a,"a",clr);
plot2(b,"b",clr);
if a > b and a[1] < b[1] Then
{
tx = text_new(sDate,sTime,H,"▼");
Text_SetStyle(tx,2,1);
Text_SetColor(tx,clr);
}
if b > a and b[1] < a[1] Then
{
tx = text_new(sDate,sTime,L,"▲");
Text_SetStyle(tx,2,0);
Text_SetColor(tx,clr);
}
input : length2(10),multiplier(3.0),emaPeriod(200);
var : supertrend(0),highestHigh(0),lowestLow(0);
var : atrv(0),ii(0),supertrendcolor(0);
var : ema200(0),emaColor(0);
ATRV = ATR(length2);
supertrend = 0;
highestHigh = 0;
lowestLow = 0;
for ii = length2 downto 1
{
if close[ii] > close[ii+1] Then
{
if highestHigh == 0 or (highestHigh > 0 and high[ii] > highestHigh) Then
highestHigh = high[ii];
}
else
{
if lowestLow == 0 or (lowestLow > 0 and low[ii] < lowestLow) Then
lowestLow = low[ii];
}
}
supertrend = iff(close > close[1] , lowestLow + multiplier * ATRV, highestHigh - multiplier * ATRV);
supertrendColor = iff(supertrend > ema(close, emaPeriod) , green , red);
ema200 = ema(close, emaPeriod);
emaColor = iff(close > ema200 , Red , Green);
plot3(supertrend, "Supertrend",supertrendColor);
plot4(ema200,"200 EMA",emaColor);
즐거운 하루되세요
> 매치다2 님이 쓴 글입니다.
> 제목 : 오랜만에 인사드리네요 잘부탁 드립니다
> 1번지표 2번지표 하나의 지표로 부탁드립니다
1,
input : length(24);
var : src(0),a(0),p(0),b(0),clr(0),tx(0);
src = (h+l)/2;
a = wma((2 * wma(src,length / 2)) - wma(src, length), round(sqrt(length),0));
p = length/2;
b = wma(wma(close,p/3)*3 - wma(close,p/2) - wma(close,p),p);
clr = iff(b > a , lime , red);
plot1(a,"a",clr);
plot2(b,"b",clr);
if a > b and a[1] < b[1] Then
{
tx = text_new(sDate,sTime,H,"▼");
Text_SetStyle(tx,2,1);
Text_SetColor(tx,clr);
}
if b > a and b[1] < a[1] Then
{
tx = text_new(sDate,sTime,L,"▲");
Text_SetStyle(tx,2,0);
Text_SetColor(tx,clr);
}
2,
input : length(10),multiplier(3.0),emaPeriod(200);
var : supertrend(0),highestHigh(0),lowestLow(0);
var : atrv(0),ii(0),supertrendcolor(0);
var : ema200(0),emaColor(0);
ATRV = ATR(length);
supertrend = 0;
highestHigh = 0;
lowestLow = 0;
for ii = length downto 1
{
if close[ii] > close[ii+1] Then
{
if highestHigh == 0 or (highestHigh > 0 and high[ii] > highestHigh) Then
highestHigh = high[ii];
}
else
{
if lowestLow == 0 or (lowestLow > 0 and low[ii] < lowestLow) Then
lowestLow = low[ii];
}
}
supertrend = iff(close > close[1] , lowestLow + multiplier * ATRV, highestHigh - multiplier * ATRV);
supertrendColor = iff(supertrend > ema(close, emaPeriod) , green , red);
ema200 = ema(close, emaPeriod);
emaColor = iff(close > ema200 , Red , Green);
plot1(supertrend, "Supertrend",supertrendColor);
plot2(ema200,"200 EMA",emaColor);
1번 2번 지표를 하나의지표로 만들어주세요