항상 많은 도움에 고맙습니다.
* 아래 수식이 안되는데 어느 부분이 잘못 되었나요?
* 수식: a 와 b가 10봉 이내 3개 이상 이면 "■" 찍기
## <아래>
if countif(LRLv8-PriceScale*3 < LRLv8[1]-PriceScale*3 and
(LRLv8-PriceScale*3 < LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[6]-PriceScale*3)
<
(LRLv8-PriceScale*3 > LRLv8[1]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[6]-PriceScale*3),10) >= 3 Then {TX21 = Text_New_Self(sdate,stime,LRLv8-PriceScale*3,"■"); Text_SetStyle(TX21,2,2); Text_SetColor(TX21, RED ); Text_SetSize(TX21,13); }
* 고맙 습니다 수고하십시요.
답변 1
예스스탁
예스스탁 답변
2021-02-08 14:15:33
안녕하세요
예스스탁입니다.
2개의 조건식중 한개이상이므로 or로 연결되어야 합니다.
var : LRLv8(0),TX21(0);
Condition1 = LRLv8-PriceScale*3 < LRLv8[1]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[6]-PriceScale*3;
Condition2 = LRLv8-PriceScale*3 > LRLv8[1]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[6]-PriceScale*3;
if countif(Condition1 or Condition2,10) >= 3 Then
{
TX21 = Text_New_Self(sdate,stime,LRLv8-PriceScale*3,"■");
Text_SetStyle(TX21,2,2);
Text_SetColor(TX21, RED );
Text_SetSize(TX21,13);
}
즐거운 하루되세요
> 요타 님이 쓴 글입니다.
> 제목 : 수식 좀 부탁 드립니다.
> 항상 많은 도움에 고맙습니다.
* 아래 수식이 안되는데 어느 부분이 잘못 되었나요?
* 수식: a 와 b가 10봉 이내 3개 이상 이면 "■" 찍기
## <아래>
if countif(LRLv8-PriceScale*3 < LRLv8[1]-PriceScale*3 and
(LRLv8-PriceScale*3 < LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 < LRLv8[6]-PriceScale*3)
<
(LRLv8-PriceScale*3 > LRLv8[1]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[2]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[3]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[4]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[5]-PriceScale*3 and
LRLv8-PriceScale*3 > LRLv8[6]-PriceScale*3),10) >= 3 Then {TX21 = Text_New_Self(sdate,stime,LRLv8-PriceScale*3,"■"); Text_SetStyle(TX21,2,2); Text_SetColor(TX21, RED ); Text_SetSize(TX21,13); }
* 고맙 습니다 수고하십시요.