답변완료
지표 확인 좀 요청 드립니다.
* 좋은 한주 되십시요^^
* 아래 수식에서 점찍기 요청 드립니다.
기준 : 신호 발생후 5개봉 경과후 6번째 봉부터
5봉간 신호발생 가격을 돌파한적이 한번도 없고
6봉부터 신호발생 가격을 돌파 할 경우 점찍기
<아래수식>
input : P(10),n(8),틱(10);
input : 틱1(10),틱2(20),틱3(50);
var : TX(0);
var : cnt(0),LL(0),HH(0);
Array : LTL[10](0),HTL[10](0);
var : LTL1(0),LTL2(0),LTL3(0),LTL4(0),LTL5(0),LTL6(0);
var : HTL1(0),HTL2(0),HTL3(0),HTL4(0),HTL5(0),HTL6(0);
if L < Lowest(L,P)[1] and (LL == 0 or (LL > 0 and abs(L-LL) >= PriceScale*틱)) Then
{
LL = L;
For cnt = 9 DownTo 1
{
LTL[cnt] = LTL[cnt-1];
}
LTL[0] = TL_new(sDate,sTime,LL,NextBarSdate,NextBarStime,LL);
TL_SetColor(LTL[0],Black);
TL_SetSize(LTL[0],2);
TL_Delete(LTL[n]);
}
Else
{
TL_SetEnd(LTL[0],sDate,sTime,LL);
}
if H > highest(H,P)[1] and (HH == 0 or (HH > 0 and abs(H-HH) >= PriceScale*틱)) Then
{
HH = H;
For cnt = 9 DownTo 1
{
HTL[cnt] = HTL[cnt-1];
}
HTL[0] = TL_new(sDate,sTime,HH,NextBarSdate,NextBarStime,HH);
TL_SetColor(HTL[0],Magenta);
TL_SetSize(HTL[0],2);
TL_Delete(HTL[n]);
}
Else
{
TL_SetEnd(HTL[0],sDate,sTime,HH);
}
######################################################
## 점찍기
## 기준 : 신호 발생후 5봉간 5개봉 고가가 신호발생 가격을 돌파한적이 한번도 없고
## 5봉이후 고가가 신호발생 가격을 돌파할경우 점찍기
## CountIF(경과봉(5봉) 까지는 신호 발생 가격을 한번도 돌파한적이 없고
6봉 부터 봉의 고가가 발생 하면 점찍기
새로운 신호 발생 하면 새로운 신호 발생가격 적용
input : 경과봉(5) ;
var : tx71(0);
var : tx91(0);
if CrossUp(신호발생 가격,H) AND COUNT Then
{
tx71 = Text_New(sDate,sTime,H,"■");
Text_SetStyle(tx71,0,1);
Text_SetColor(tx71,Black);
Text_SetSize(tx71,15);
}
* 매번 많은 도움에 고맙습니다.
2023-11-12
792
글번호 173967
지표
답변완료
수식 문의
항상 수고 많으세요.!
키움 사용 수식입니다. 예스 수식 도움 요청합니다.
a1=ma(c,5);
a2=ma(c,120);
b1= ValueWhen(1, crossdown(a1, a2), o);
b2= CountSince(crossdown(a1, a2), date(1)!=date);
b3= ValueWhen(1, crossup(a1, a2), o);
b4= CountSince(crossup(a1, a2), date(1)!=date);
if (b2 <=b4, b1, 1,0)
2023-11-12
836
글번호 173965
지표
답변완료
문의 드립니다
input : StartTime(180000),EndTime(40000);
input : 익절틱수(0),손절틱수(50);
var : Tcond(False),entry(0);
Variables: Mom(0);
IF Endtime > starttime Then
SetStopEndofday(Endtime);
Else
{
if sDate != sDate[1] Then
SetStopEndofday(Endtime);
}
if (sdate != sdate[1] and stime >= StartTime) or
(sdate == sdate[1] and stime >= StartTime and stime[1] < StartTime) Then
{
Tcond = true;
IF Endtime <= starttime Then
{
SetStopEndofday(0);
}
}
if (sdate != sdate[1] and stime >= EndTime) or
(sdate == sdate[1] and stime >= EndTime and stime[1] < EndTime) Then
{
Tcond = False;
}
if Tcond == true Then
{
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*1 Then
{
Buy("b",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
}
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*1 Then
{
Sell("s",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then
{
Buy("b1",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then
{
Sell("s1",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then
{
Buy("b2",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then
{
Sell("s2",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*1 Then
{
Buy("b3",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*1 Then
{
Sell("s3",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then
{
Buy("b4",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then
{
Sell("s4",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then
{
Buy("b5",AtStop,(highest(H,3)+lowest(L,1))/2);
}
if MarketPosition == 1 and BarsSinceEntry == 9 Then
Sell();
if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then
{
Sell("s5",AtStop,(lowest(L,3)+highest(H,1))/2);
}
if MarketPosition == -1 and BarsSinceEntry == 9 Then
Buy();
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
위 수식어를 분봉으로 확인하고 있습니다.
일봉으로 테스트하면 실제로 장중 위 시간때에만 신호가 주어지는건지
문의해 봅니다.
2023-11-12
1113
글번호 173964
시스템