커뮤니티

wave box

프로필 이미지
고성
2026-10-13 20:45:50
80
글번호 233876
답변완료


      wt1 이  -50 이하로 내려가거나 +50 이상으로 올라가면 박스 시작. (wt2는 무관)

      wt1 이 -50 아래에서 양전환되거나, +50 이상에서 음전환되면 박스 끝. (전환 직전봉까지만 박스)

      wt1 이 -50 아래에서 양전환후 -50 이상으로 못 올라오고 음전환하면 다시 박스.

      wt1 이 +50 이상에서 음전환후 +50 아래로 안 내려오고 양전환하면 다시 박스. 감사합니다.


input : n1(16);

input : n2(32);

input : obLevel2(50);

input : osLevel2(-50);

var : ap(0),esa(0),d(0),ci(0),tci(0),wt1(0),wt2(0);

var : isConfluenceTop(False),isConfluenceBottom(False),tx(0),box1(0),box2(0);


ap = (h+l+c)/3;

esa = ema(ap, n1);

d = ema(abs(ap - esa), n1);

ci = (ap - esa) / (0.015 * d);

tci = ema(ci, n2);

wt1 = tci;

wt2 = ma(wt1, 4);

isConfluenceTop = wt1 > obLevel2 and wt1 > wt2;

isConfluenceBottom = wt1 < osLevel2 and wt1 < wt2;

if isConfluenceTop Then

{

if isConfluenceTop[1] == False Then

{

box1 = Box_New(sDate,sTime,L-1,NextBarSdate,NextBarStime,-1999);

Box_SetColor(box1,Blue);

Box_SetFill(box1,true,70);

}

Else

{

Box_SetEnd(box1,NextBarSdate,NextBarStime,-1999);

}

}

if isConfluenceBottom Then

{

if isConfluenceBottom[1] == False Then

{

box2 = Box_New(sDate,sTime,H+1,NextBarSdate,NextBarStime,1999);

Box_SetColor(box2,Red);

Box_SetFill(box2,true,70);

}

Else

{

Box_SetEnd(box2,NextBarSdate,NextBarStime,1999);

}

}

plot1(wt1, "wt1",IFf(wt1>wt1[1],Red,Blue));

plot2(obLevel2,"과매수",Gray);

plot3(osLevel2,"과매도",Gray);


if CrossUp(wt1,wt1[1]) and wt1[1] < -50 Then

{

tx = Text_New_Self(sDate,sTime,wt1-5,"●");

Text_SetColor(tx,Red);

Text_SetStyle(tx,2,2);

    Text_SetSize(tx,15);

}

if CrossDown(wt1,wt1[1]) and wt1[1] > 50 Then

{

tx = Text_New_Self(sDate,sTime,wt1+5,"●");

Text_SetColor(tx,Blue);

Text_SetStyle(tx,2,2);

    Text_SetSize(tx,15);

}

     

   

지표
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2026-10-14 15:31:05

안녕하세요 예스스탁입니다. 기존식 하단에 추가해 드립니다. input : n1(16); input : n2(32); input : obLevel2(50); input : osLevel2(-50); var : ap(0),esa(0),d(0),ci(0),tci(0),wt1(0),wt2(0); var : isConfluenceTop(False),isConfluenceBottom(False); var : tx(0),box1(0),box2(0),box(0); ap = (h+l+c)/3; esa = ema(ap, n1); d = ema(abs(ap - esa), n1); ci = (ap - esa) / (0.015 * d); tci = ema(ci, n2); wt1 = tci; wt2 = ma(wt1, 4); isConfluenceTop = wt1 > obLevel2 and wt1 > wt2; isConfluenceBottom = wt1 < osLevel2 and wt1 < wt2; if isConfluenceTop Then { if isConfluenceTop[1] == False Then { box1 = Box_New(sDate,sTime,L-1,NextBarSdate,NextBarStime,-1999); Box_SetColor(box1,Blue); Box_SetFill(box1,true,70); } Else { Box_SetEnd(box1,NextBarSdate,NextBarStime,-1999); } } if isConfluenceBottom Then { if isConfluenceBottom[1] == False Then { box2 = Box_New(sDate,sTime,H+1,NextBarSdate,NextBarStime,1999); Box_SetColor(box2,Red); Box_SetFill(box2,true,70); } Else { Box_SetEnd(box2,NextBarSdate,NextBarStime,1999); } } plot1(wt1, "wt1",IFf(wt1>wt1[1],Red,Blue)); plot2(obLevel2,"과매수",Gray); plot3(osLevel2,"과매도",Gray); var : t(0); if wt1 > wt1[1] Then t = 1; Else t = -1; if CrossUp(wt1,wt1[1]) and wt1[1] < -50 Then { tx = Text_New_Self(sDate,sTime,wt1-5,"●"); Text_SetColor(tx,Red); Text_SetStyle(tx,2,2); Text_SetSize(tx,15); } if CrossDown(wt1,wt1[1]) and wt1[1] > 50 Then { tx = Text_New_Self(sDate,sTime,wt1+5,"●"); Text_SetColor(tx,Blue); Text_SetStyle(tx,2,2); Text_SetSize(tx,15); } if CrossDown(wt1,osLevel2) Then { box = Box_New(sDate,sTime,99999999,NextBarSdate,NextBarStime,-99999999); Box_SetColor(box,Red); Box_SetFill(box,true); } Else { if wt1 < osLevel2 Then { if t == -1 and t != t[1] Then { box = Box_New(sDate,sTime,99999999,NextBarSdate,NextBarStime,-99999999); Box_SetColor(box,Red); Box_SetFill(box,true); } if t == -1 Then { Box_SetEnd(box,sDate,Stime,-9999999999); } } } if CrossUp(wt1,obLevel2) Then { box = Box_New(sDate,sTime,99999999,NextBarSdate,NextBarStime,-99999999); Box_SetColor(box,Blue); Box_SetFill(box,true); } Else { if wt1 > obLevel2 Then { if t == 1 and t != t[1] Then { box = Box_New(sDate,sTime,99999999,NextBarSdate,NextBarStime,-99999999); Box_SetColor(box,Blue); Box_SetFill(box,true); } if t == 1 Then { Box_SetEnd(box,sDate,Stime,-9999999999); } } } 즐거운 하루되세요