커뮤니티
수식부탁드립니다----------
2012-06-11 16:55:12
644
글번호 51881
Input : 진폭보정(0.00015),강제보정(0),보정시간봉(0);
Var : LENGTH9(5),value(0),순괴리시작점(-2),호종전봉차(0), LENGTH1(1), period(1),일괄보정(0);
Var : TEMA1(0),cbiul(0),vbiul(0),종가(0),tbiul(0),cvcha(0),cvchacha(0),
antit(0),antid(0),temcvcha(0),goldjisu(0),폭2(0);
var : gweri(0), gweritem(0);
var: jisucha(0),temcvchacha(0),goldt(0),goldsell(0),goldbuy(0),goldt11(0);
var:LENGTH8(1),goldjisutem(00),goldt11tem(0),nagagoldt(0),중값(0),togoldjisu(0),
gwerigugan(0),잔량차중값(0),횟수1(3),횟수2(3),첫봉골드(0);
var : J1(0),J2(0),J3(0),EP(0);
var:TEMA81(0),sEp(0),sT1(0),sT2(0),sT3(0),sTEMA82(0),LENGTH5(1);
if stime >= 090000 and stime <= 143000 then{
value = (ma(bids,period)-ma(asks,period))/2;
중값=((h-l)/2)+l;
if dayindex+1 < LENGTH9 Then{
var81 = DayHigh;
var82 = DayLow;
}
Else{
var81 = highest(H,LENGTH5);
var82 = Lowest(L,LENGTH5);
}
value81 = (var81 - var82)/2+var82;
sEp = 2/(LENGTH9+1);
if dayindex == 0 Then
sT1 = value81;
Else
sT1 = value81*sEP + sT1[1] * (1-sEP);
if dayindex <= 1 Then
sT2 = sT1;
Else
sT2 = sT1*sEP + sT2[1] * (1-sEP);
if dayindex <= 2 Then
sT3 = sT2;
Else
sT3 = sT2*sEP + sT3[1] * (1-sEP);
sTEMA82 = (3 * sT1) - (3 * sT2) + (sT3);
plot11(sTEMA82,"장기테마등락",iff(sTEMA82>sTEMA82[1]+0.01,red,iff(sTEMA82<sTEMA82[1]-0.01,BLUE,WHITE)));
//장기최고저테마값 끝**************************************************
//골드지수지정**************************************************
if dayindex == 0 Then{
if value > 0 then
value=DayOpen-Value;
Else
value=DayOpen+Value;
}
togoldjisu= value*진폭보정+DayOpen;
if dayindex == 0 Then{
if 중값 > togoldjisu Then
var1 = 중값-togoldjisu;
Else
var1 = togoldjisu-중값;
}
goldjisu=(togoldjisu+var1+일괄보정)+강제보정;
//*골드지수테마--------------------------------------------------------
if dayindex == 0 Then{
일괄보정 = 0;
}
EP = 2/(LENGTH9+1);
if dayindex == 0 Then
j1 = goldjisu;
Else
J1 = (goldjisu)*EP+j1[1]*(1-Ep);
if dayindex <= 1 Then
j2 = J1;
Else
J2 = J1*EP+j2[1]*(1-Ep);
if dayindex <= 3 Then
j3 = J2;
Else
J3 = J2*EP+j3[1]*(1-Ep);
goldjisutem = (3 * J1) - (3 * J2) + J3;
//*************************************일괄보정---------------------------------------------------------
//goldjisu연속4번한방향이면 보정***
/*
if CountIF (value[1] < value ,4) >= 4 or CountIF (value[1] > value ,4) >= 4 then{
일괄보정 = 일괄보정 - goldjisu + 중값+강제보정;
plot55(중값,"보정");
}
*/
/*
//goldjisu 중값과 벌어지면 보정***********5*****0.0025이 유효***
if abs(goldjisu - 중값) > 3.2 then{
value = 0;
일괄보정 = 일괄보정 -( (goldjisu + goldjisu [1]+goldjisu [2])/3)+((중값+중값[1]+중값[2])/3)+강제보정;
//일괄보정 = 일괄보정 -( goldjisu[10]+중값[10])+강제보정;
plot55(중값,"보정");
}
*/
//3째봉에보정***************5*****0.005이 유효***
if dayindex == 0 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
//*보정시간지정보정**********************************
if stime == 보정시간봉 then{
// if dayindex == 보정위치봉 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
//골드지수지표표시**********************************
plot1(goldjisu,"골드지수",
iff((중값 > goldjisu+0.1 and goldjisu < goldjisu[1])
or ((CountIF ( goldjisu < goldjisu[1],3) >= 3) and 중값+0.1 < goldjisu) ,YELLOW,
iff((중값 < goldjisu-0.1 and goldjisu > goldjisu[1])
or ((CountIF ( goldjisu > goldjisu[1],3) >= 3) and 중값-0.1 > goldjisu),YELLOW,YELLOW)));
/*
//********length1 조절*******************
if abs(goldjisu - 중값) > 0.2 then{
length9 = 5;
}
if abs(goldjisu - 중값) < 0.2 then{
length9 = 100;
}
if abs(value-value[2]) > 800 then{
length9 = 5;
}
*/
//골드지수테마지표표시**********************************
plot2(goldjisutem,"골드지수테마",
iff((중값 > goldjisutem+0.1 and goldjisutem < goldjisutem[1])
or ((CountIF ( goldjisutem < goldjisutem[1],3) >= 3) and 중값+0.2 < goldjisutem) ,BLUE,
iff((중값 < goldjisutem-0.1 and goldjisutem > goldjisutem[1])
or ((CountIF ( goldjisutem > goldjisutem[1],3) >= 3) and 중값-0.2 > goldjisutem),red,WHITE)));
//countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot2(goldjisutem,"골드지수테마",BLACK,def,0.005);#14시 이후
gweri = goldjisu-중값;
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot1(goldjisu,"골드지수",BLACK,def,0.05);#14시 이후
//*****************************
if stime >= 090100 and stime <= 143000 then{
goldt11 = (gweri+DayOpen+순괴리시작점);
//goldt11 = (value*0.00035+DayOpen);
plot3(goldt11,"순괴리");
}
if stime <= 090000 or stime >= 143000 Then
plot3(goldt11,"순괴리",BLACK,def,0.05);#14시 이후
gwerigugan=goldt11-DayOpen-순괴리시작점;
plot5(gwerigugan,"괴리구간",
iff( gwerigugan > gwerigugan[1] ,red,
iff( gwerigugan < gwerigugan[1] ,BLUE,WHITE)));
var : g1(0),g2(0),g3(0),gEP(0);
gEP = 2/(LENGTH9+1);
if dayindex == 0 Then
g1 = goldt11;
Else
g1 = (goldt11)*gEP+g1[1]*(1-gEp);
if dayindex <= 1 Then
g2 = g1;
Else
g2 = g1*gEP+g2[1]*(1-gEp);
if dayindex <= 3 Then
g3 = g2;
Else
g3 = g2*gEP+g3[1]*(1-gEp);
goldt11tem = (3 * g1) - (3 * g2) + g3;
if stime >= 090100 and stime <= 143000 then{
plot4(goldt11tem,"순괴리테마",iff(goldt11tem>DayOpen+순괴리시작점,red,iff(goldt11tem<DayOpen+순괴리시작점,BLUE,WHITE)));
}
if stime <= 090000 or stime >= 143000 Then
plot4(goldt11tem,"순괴리테마",BLACK,def,0.05);#14시 이후
//plot12(c-(goldjisu+var1));
var : grg1(0),grg2(0),grg3(0),grgEP(0);
grgEP = 2/(LENGTH9+1);
if dayindex == 0 Then
grg1 = gweri;
Else
grg1 = (gweri)*grgEP+grg1[1]*(1-grgEp);
if dayindex <= 1 Then
grg2 = grg1;
Else
grg2 = grg1*grgEP+grg2[1]*(1-grgEp);
if dayindex <= 3 Then
grg3 = grg2;
Else
grg3 = grg2*grgEP+grg3[1]*(1-grgEp);
gweritem = (3 * grg1) - (3 * grg2) + grg3;
//plot6(gweritem *3.2+DayOpen+괴리테마시작점,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
plot6(gweritem ,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
/*
PlotBaseLine1(0,"기준선");
PlotBaseLine2(1,"기준선",GRAY);
PlotBaseLine3(-1,"기준선",GRAY);
PlotBaseLine4(0.5,"기준선",BLUE);
PlotBaseLine5(-0.5,"기준선",BLUE);
*/
plot7(DayOpen+순괴리시작점,"당일시가");
if stime <= 090000 or stime >= 143000 Then
plot7(DayOpen+순괴리시작점,"당일시가",BLACK,def,0.05);#14시 이후
/*
*/
//뾰족**gweri*************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if
countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
and countif ( goldjisu[1]+0.1 >goldjisu,2) >=1
//and goldjisu[1] > goldjisu
and gweri > 0.87
then{
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if
countif ( goldjisu[1]-0.15 >goldjisu,8) >=3
and countif ( goldjisu[1]-0.05 >goldjisu,7) >=2
and goldjisu[1] < goldjisu
and (goldjisu-중값)<-0.5
then{
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
/*
if countif (( gweri[1]-0.1) >gweri,4) >=4 then{
plot44(goldjisu-1,"원웨이");
}
if countif (( gweri[1]+0.1) <gweri,4) >=4 then{
plot44(goldjisu+1,"원웨이");
}
*/
//과괴리**************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if ( countif (중값 >= 중값[10]+0.00 and goldjisu <goldjisu[10] - 0.1,5) >=1
and dayindex > 40)
then {
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if ( countif (중값 <= 중값[10]+0.00 and goldjisu >goldjisu[10] + 0.1,5) >=1
and dayindex > 40)
then {
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
//goldjisu와 가격이 0.1이탈시*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (goldjisu[1] >= 중값[1]+ 0.05,3) >=3
then{
plot22(goldjisu-0.2,"기울기매도");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if (goldjisu - h) > 0.2 then{
plot33(goldjisu+0.2,"기울기매수");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
var : TSF(0),Period44(14);
TSF = LRL(C,Period44)+LRS(C,Period44);
Plot44(TSF,"TSF") ;
plot44(TSF,"TSF",iff(TSF>TSF[1]+0.01,red,iff(TSF<TSF[1]-0.01,BLUE,WHITE)));
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot44(TSF,"TSF",BLACK,def,0.05);#14시 이후
plot66(중값,"중값",iff(중값>중값[1]+0.01,red,iff(중값<중값[1]-0.01,BLUE,WHITE)));
}
plot77(h+0.5,"고가");
plot88(l-0.5,"저가");
/*
//호가잔량큰폭2개이상*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif ((value[1] -value) > 300 ,3) >=3
then{
plot22(goldjisu-0.1,"기울기매도",BLUE);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (( value -value[1]) > 300 ,3) >=3
then{
plot33(goldjisu+0.2,"기울기매수",PINK);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
중간에 짤라서 올릴 능력이안되 할수없이 그냥 올립니다 (첨부참고해주세요)
보정하면 중값과 goldjisu 를 일치시켜주세요 지금은 goldjisu가 약간 아래 있거든요
부탁드립니다
수고하세요
- 1. 보정.xlsx (0.03 MB)
답변 1
예스스탁 예스스탁 답변
2012-06-12 13:48:17
안녕하세요
예스스탁입니다.
Input : 진폭보정(0.00015),강제보정(0),보정시간봉(0);
Var : LENGTH9(5),value(0),순괴리시작점(-2),호종전봉차(0), LENGTH1(1), period(1),일괄보정(0);
Var : TEMA1(0),cbiul(0),vbiul(0),종가(0),tbiul(0),cvcha(0),cvchacha(0),
antit(0),antid(0),temcvcha(0),goldjisu(0),폭2(0);
var : gweri(0), gweritem(0);
var: jisucha(0),temcvchacha(0),goldt(0),goldsell(0),goldbuy(0),goldt11(0);
var:LENGTH8(1),goldjisutem(00),goldt11tem(0),nagagoldt(0),중값(0),togoldjisu(0),
gwerigugan(0),잔량차중값(0),횟수1(3),횟수2(3),첫봉골드(0);
var : J1(0),J2(0),J3(0),EP(0),차이(0);
var:TEMA81(0),sEp(0),sT1(0),sT2(0),sT3(0),sTEMA82(0),LENGTH5(1);
if stime >= 090000 and stime <= 143000 then{
value = (ma(bids,period)-ma(asks,period))/2;
중값=((h-l)/2)+l;
if dayindex+1 < LENGTH9 Then{
var81 = DayHigh;
var82 = DayLow;
}
Else{
var81 = highest(H,LENGTH5);
var82 = Lowest(L,LENGTH5);
}
value81 = (var81 - var82)/2+var82;
sEp = 2/(LENGTH9+1);
if dayindex == 0 Then
sT1 = value81;
Else
sT1 = value81*sEP + sT1[1] * (1-sEP);
if dayindex <= 1 Then
sT2 = sT1;
Else
sT2 = sT1*sEP + sT2[1] * (1-sEP);
if dayindex <= 2 Then
sT3 = sT2;
Else
sT3 = sT2*sEP + sT3[1] * (1-sEP);
sTEMA82 = (3 * sT1) - (3 * sT2) + (sT3);
plot11(sTEMA82,"장기테마등락",iff(sTEMA82>sTEMA82[1]+0.01,red,iff(sTEMA82<sTEMA82[1]-0.01,BLUE,WHITE)));
//장기최고저테마값 끝**************************************************
//골드지수지정**************************************************
if dayindex == 0 Then{
if value > 0 then
value=DayOpen-Value;
Else
value=DayOpen+Value;
}
togoldjisu= value*진폭보정+DayOpen;
if dayindex == 0 Then{
if 중값 > togoldjisu Then
var1 = 중값-togoldjisu;
Else
var1 = togoldjisu-중값;
}
goldjisu=(togoldjisu+var1+일괄보정)+강제보정;
//*골드지수테마--------------------------------------------------------
if dayindex == 0 Then{
일괄보정 = 0;
}
EP = 2/(LENGTH9+1);
if dayindex == 0 Then
j1 = goldjisu;
Else
J1 = (goldjisu)*EP+j1[1]*(1-Ep);
if dayindex <= 1 Then
j2 = J1;
Else
J2 = J1*EP+j2[1]*(1-Ep);
if dayindex <= 3 Then
j3 = J2;
Else
J3 = J2*EP+j3[1]*(1-Ep);
goldjisutem = (3 * J1) - (3 * J2) + J3;
//*************************************일괄보정---------------------------------------------------------
//goldjisu연속4번한방향이면 보정***
/*
if CountIF (value[1] < value ,4) >= 4 or CountIF (value[1] > value ,4) >= 4 then{
일괄보정 = 일괄보정 - goldjisu + 중값+강제보정;
plot55(중값,"보정");
}
*/
/*
//goldjisu 중값과 벌어지면 보정***********5*****0.0025이 유효***
if abs(goldjisu - 중값) > 3.2 then{
value = 0;
일괄보정 = 일괄보정 -( (goldjisu + goldjisu [1]+goldjisu [2])/3)+((중값+중값[1]+중값[2])/3)+강제보정;
//일괄보정 = 일괄보정 -( goldjisu[10]+중값[10])+강제보정;
plot55(중값,"보정");
}
*/
//3째봉에보정***************5*****0.005이 유효***
if dayindex == 0 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
//*보정시간지정보정**********************************
if stime == 보정시간봉 then{
// if dayindex == 보정위치봉 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
if stime < 보정시간봉 Then
차이 = 0;
if stime == 보정시간봉 Then
차이 = 중값 - goldjisu;
//골드지수지표표시**********************************
plot1(goldjisu+차이,"골드지수",
iff((중값 > goldjisu+0.1 and goldjisu < goldjisu[1])
or ((CountIF ( goldjisu < goldjisu[1],3) >= 3) and 중값+0.1 < goldjisu) ,YELLOW,
iff((중값 < goldjisu-0.1 and goldjisu > goldjisu[1])
or ((CountIF ( goldjisu > goldjisu[1],3) >= 3) and 중값-0.1 > goldjisu),YELLOW,YELLOW)));
/*
//********length1 조절*******************
if abs(goldjisu - 중값) > 0.2 then{
length9 = 5;
}
if abs(goldjisu - 중값) < 0.2 then{
length9 = 100;
}
if abs(value-value[2]) > 800 then{
length9 = 5;
}
*/
//골드지수테마지표표시**********************************
plot2(goldjisutem,"골드지수테마",
iff((중값 > goldjisutem+0.1 and goldjisutem < goldjisutem[1])
or ((CountIF ( goldjisutem < goldjisutem[1],3) >= 3) and 중값+0.2 < goldjisutem) ,BLUE,
iff((중값 < goldjisutem-0.1 and goldjisutem > goldjisutem[1])
or ((CountIF ( goldjisutem > goldjisutem[1],3) >= 3) and 중값-0.2 > goldjisutem),red,WHITE)));
//countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot2(goldjisutem,"골드지수테마",BLACK,def,0.005);#14시 이후
gweri = goldjisu-중값;
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot1(goldjisu,"골드지수",BLACK,def,0.05);#14시 이후
//*****************************
if stime >= 090100 and stime <= 143000 then{
goldt11 = (gweri+DayOpen+순괴리시작점);
//goldt11 = (value*0.00035+DayOpen);
plot3(goldt11,"순괴리");
}
if stime <= 090000 or stime >= 143000 Then
plot3(goldt11,"순괴리",BLACK,def,0.05);#14시 이후
gwerigugan=goldt11-DayOpen-순괴리시작점;
plot5(gwerigugan,"괴리구간",
iff( gwerigugan > gwerigugan[1] ,red,
iff( gwerigugan < gwerigugan[1] ,BLUE,WHITE)));
var : g1(0),g2(0),g3(0),gEP(0);
gEP = 2/(LENGTH9+1);
if dayindex == 0 Then
g1 = goldt11;
Else
g1 = (goldt11)*gEP+g1[1]*(1-gEp);
if dayindex <= 1 Then
g2 = g1;
Else
g2 = g1*gEP+g2[1]*(1-gEp);
if dayindex <= 3 Then
g3 = g2;
Else
g3 = g2*gEP+g3[1]*(1-gEp);
goldt11tem = (3 * g1) - (3 * g2) + g3;
if stime >= 090100 and stime <= 143000 then{
plot4(goldt11tem,"순괴리테마",iff(goldt11tem>DayOpen+순괴리시작점,red,iff(goldt11tem<DayOpen+순괴리시작점,BLUE,WHITE)));
}
if stime <= 090000 or stime >= 143000 Then
plot4(goldt11tem,"순괴리테마",BLACK,def,0.05);#14시 이후
//plot12(c-(goldjisu+var1));
var : grg1(0),grg2(0),grg3(0),grgEP(0);
grgEP = 2/(LENGTH9+1);
if dayindex == 0 Then
grg1 = gweri;
Else
grg1 = (gweri)*grgEP+grg1[1]*(1-grgEp);
if dayindex <= 1 Then
grg2 = grg1;
Else
grg2 = grg1*grgEP+grg2[1]*(1-grgEp);
if dayindex <= 3 Then
grg3 = grg2;
Else
grg3 = grg2*grgEP+grg3[1]*(1-grgEp);
gweritem = (3 * grg1) - (3 * grg2) + grg3;
//plot6(gweritem *3.2+DayOpen+괴리테마시작점,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
plot6(gweritem ,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
/*
PlotBaseLine1(0,"기준선");
PlotBaseLine2(1,"기준선",GRAY);
PlotBaseLine3(-1,"기준선",GRAY);
PlotBaseLine4(0.5,"기준선",BLUE);
PlotBaseLine5(-0.5,"기준선",BLUE);
*/
plot7(DayOpen+순괴리시작점,"당일시가");
if stime <= 090000 or stime >= 143000 Then
plot7(DayOpen+순괴리시작점,"당일시가",BLACK,def,0.05);#14시 이후
/*
*/
//뾰족**gweri*************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if
countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
and countif ( goldjisu[1]+0.1 >goldjisu,2) >=1
//and goldjisu[1] > goldjisu
and gweri > 0.87
then{
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if
countif ( goldjisu[1]-0.15 >goldjisu,8) >=3
and countif ( goldjisu[1]-0.05 >goldjisu,7) >=2
and goldjisu[1] < goldjisu
and (goldjisu-중값)<-0.5
then{
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
/*
if countif (( gweri[1]-0.1) >gweri,4) >=4 then{
plot44(goldjisu-1,"원웨이");
}
if countif (( gweri[1]+0.1) <gweri,4) >=4 then{
plot44(goldjisu+1,"원웨이");
}
*/
//과괴리**************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if ( countif (중값 >= 중값[10]+0.00 and goldjisu <goldjisu[10] - 0.1,5) >=1
and dayindex > 40)
then {
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if ( countif (중값 <= 중값[10]+0.00 and goldjisu >goldjisu[10] + 0.1,5) >=1
and dayindex > 40)
then {
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
//goldjisu와 가격이 0.1이탈시*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (goldjisu[1] >= 중값[1]+ 0.05,3) >=3
then{
plot22(goldjisu-0.2,"기울기매도");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if (goldjisu - h) > 0.2 then{
plot33(goldjisu+0.2,"기울기매수");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
var : TSF(0),Period44(14);
TSF = LRL(C,Period44)+LRS(C,Period44);
Plot44(TSF,"TSF") ;
plot44(TSF,"TSF",iff(TSF>TSF[1]+0.01,red,iff(TSF<TSF[1]-0.01,BLUE,WHITE)));
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot44(TSF,"TSF",BLACK,def,0.05);#14시 이후
plot66(중값,"중값",iff(중값>중값[1]+0.01,red,iff(중값<중값[1]-0.01,BLUE,WHITE)));
}
plot77(h+0.5,"고가");
plot88(l-0.5,"저가");
/*
//호가잔량큰폭2개이상*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif ((value[1] -value) > 300 ,3) >=3
then{
plot22(goldjisu-0.1,"기울기매도",BLUE);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (( value -value[1]) > 300 ,3) >=3
then{
plot33(goldjisu+0.2,"기울기매수",PINK);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
즐거운 하루되세요
> leekss1 님이 쓴 글입니다.
> 제목 : 수식부탁드립니다----------
> Input : 진폭보정(0.00015),강제보정(0),보정시간봉(0);
Var : LENGTH9(5),value(0),순괴리시작점(-2),호종전봉차(0), LENGTH1(1), period(1),일괄보정(0);
Var : TEMA1(0),cbiul(0),vbiul(0),종가(0),tbiul(0),cvcha(0),cvchacha(0),
antit(0),antid(0),temcvcha(0),goldjisu(0),폭2(0);
var : gweri(0), gweritem(0);
var: jisucha(0),temcvchacha(0),goldt(0),goldsell(0),goldbuy(0),goldt11(0);
var:LENGTH8(1),goldjisutem(00),goldt11tem(0),nagagoldt(0),중값(0),togoldjisu(0),
gwerigugan(0),잔량차중값(0),횟수1(3),횟수2(3),첫봉골드(0);
var : J1(0),J2(0),J3(0),EP(0);
var:TEMA81(0),sEp(0),sT1(0),sT2(0),sT3(0),sTEMA82(0),LENGTH5(1);
if stime >= 090000 and stime <= 143000 then{
value = (ma(bids,period)-ma(asks,period))/2;
중값=((h-l)/2)+l;
if dayindex+1 < LENGTH9 Then{
var81 = DayHigh;
var82 = DayLow;
}
Else{
var81 = highest(H,LENGTH5);
var82 = Lowest(L,LENGTH5);
}
value81 = (var81 - var82)/2+var82;
sEp = 2/(LENGTH9+1);
if dayindex == 0 Then
sT1 = value81;
Else
sT1 = value81*sEP + sT1[1] * (1-sEP);
if dayindex <= 1 Then
sT2 = sT1;
Else
sT2 = sT1*sEP + sT2[1] * (1-sEP);
if dayindex <= 2 Then
sT3 = sT2;
Else
sT3 = sT2*sEP + sT3[1] * (1-sEP);
sTEMA82 = (3 * sT1) - (3 * sT2) + (sT3);
plot11(sTEMA82,"장기테마등락",iff(sTEMA82>sTEMA82[1]+0.01,red,iff(sTEMA82<sTEMA82[1]-0.01,BLUE,WHITE)));
//장기최고저테마값 끝**************************************************
//골드지수지정**************************************************
if dayindex == 0 Then{
if value > 0 then
value=DayOpen-Value;
Else
value=DayOpen+Value;
}
togoldjisu= value*진폭보정+DayOpen;
if dayindex == 0 Then{
if 중값 > togoldjisu Then
var1 = 중값-togoldjisu;
Else
var1 = togoldjisu-중값;
}
goldjisu=(togoldjisu+var1+일괄보정)+강제보정;
//*골드지수테마--------------------------------------------------------
if dayindex == 0 Then{
일괄보정 = 0;
}
EP = 2/(LENGTH9+1);
if dayindex == 0 Then
j1 = goldjisu;
Else
J1 = (goldjisu)*EP+j1[1]*(1-Ep);
if dayindex <= 1 Then
j2 = J1;
Else
J2 = J1*EP+j2[1]*(1-Ep);
if dayindex <= 3 Then
j3 = J2;
Else
J3 = J2*EP+j3[1]*(1-Ep);
goldjisutem = (3 * J1) - (3 * J2) + J3;
//*************************************일괄보정---------------------------------------------------------
//goldjisu연속4번한방향이면 보정***
/*
if CountIF (value[1] < value ,4) >= 4 or CountIF (value[1] > value ,4) >= 4 then{
일괄보정 = 일괄보정 - goldjisu + 중값+강제보정;
plot55(중값,"보정");
}
*/
/*
//goldjisu 중값과 벌어지면 보정***********5*****0.0025이 유효***
if abs(goldjisu - 중값) > 3.2 then{
value = 0;
일괄보정 = 일괄보정 -( (goldjisu + goldjisu [1]+goldjisu [2])/3)+((중값+중값[1]+중값[2])/3)+강제보정;
//일괄보정 = 일괄보정 -( goldjisu[10]+중값[10])+강제보정;
plot55(중값,"보정");
}
*/
//3째봉에보정***************5*****0.005이 유효***
if dayindex == 0 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
//*보정시간지정보정**********************************
if stime == 보정시간봉 then{
// if dayindex == 보정위치봉 then{
일괄보정 = 일괄보정 -goldjisu +중값+강제보정;
plot55(중값,"보정");
}
//골드지수지표표시**********************************
plot1(goldjisu,"골드지수",
iff((중값 > goldjisu+0.1 and goldjisu < goldjisu[1])
or ((CountIF ( goldjisu < goldjisu[1],3) >= 3) and 중값+0.1 < goldjisu) ,YELLOW,
iff((중값 < goldjisu-0.1 and goldjisu > goldjisu[1])
or ((CountIF ( goldjisu > goldjisu[1],3) >= 3) and 중값-0.1 > goldjisu),YELLOW,YELLOW)));
/*
//********length1 조절*******************
if abs(goldjisu - 중값) > 0.2 then{
length9 = 5;
}
if abs(goldjisu - 중값) < 0.2 then{
length9 = 100;
}
if abs(value-value[2]) > 800 then{
length9 = 5;
}
*/
//골드지수테마지표표시**********************************
plot2(goldjisutem,"골드지수테마",
iff((중값 > goldjisutem+0.1 and goldjisutem < goldjisutem[1])
or ((CountIF ( goldjisutem < goldjisutem[1],3) >= 3) and 중값+0.2 < goldjisutem) ,BLUE,
iff((중값 < goldjisutem-0.1 and goldjisutem > goldjisutem[1])
or ((CountIF ( goldjisutem > goldjisutem[1],3) >= 3) and 중값-0.2 > goldjisutem),red,WHITE)));
//countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot2(goldjisutem,"골드지수테마",BLACK,def,0.005);#14시 이후
gweri = goldjisu-중값;
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot1(goldjisu,"골드지수",BLACK,def,0.05);#14시 이후
//*****************************
if stime >= 090100 and stime <= 143000 then{
goldt11 = (gweri+DayOpen+순괴리시작점);
//goldt11 = (value*0.00035+DayOpen);
plot3(goldt11,"순괴리");
}
if stime <= 090000 or stime >= 143000 Then
plot3(goldt11,"순괴리",BLACK,def,0.05);#14시 이후
gwerigugan=goldt11-DayOpen-순괴리시작점;
plot5(gwerigugan,"괴리구간",
iff( gwerigugan > gwerigugan[1] ,red,
iff( gwerigugan < gwerigugan[1] ,BLUE,WHITE)));
var : g1(0),g2(0),g3(0),gEP(0);
gEP = 2/(LENGTH9+1);
if dayindex == 0 Then
g1 = goldt11;
Else
g1 = (goldt11)*gEP+g1[1]*(1-gEp);
if dayindex <= 1 Then
g2 = g1;
Else
g2 = g1*gEP+g2[1]*(1-gEp);
if dayindex <= 3 Then
g3 = g2;
Else
g3 = g2*gEP+g3[1]*(1-gEp);
goldt11tem = (3 * g1) - (3 * g2) + g3;
if stime >= 090100 and stime <= 143000 then{
plot4(goldt11tem,"순괴리테마",iff(goldt11tem>DayOpen+순괴리시작점,red,iff(goldt11tem<DayOpen+순괴리시작점,BLUE,WHITE)));
}
if stime <= 090000 or stime >= 143000 Then
plot4(goldt11tem,"순괴리테마",BLACK,def,0.05);#14시 이후
//plot12(c-(goldjisu+var1));
var : grg1(0),grg2(0),grg3(0),grgEP(0);
grgEP = 2/(LENGTH9+1);
if dayindex == 0 Then
grg1 = gweri;
Else
grg1 = (gweri)*grgEP+grg1[1]*(1-grgEp);
if dayindex <= 1 Then
grg2 = grg1;
Else
grg2 = grg1*grgEP+grg2[1]*(1-grgEp);
if dayindex <= 3 Then
grg3 = grg2;
Else
grg3 = grg2*grgEP+grg3[1]*(1-grgEp);
gweritem = (3 * grg1) - (3 * grg2) + grg3;
//plot6(gweritem *3.2+DayOpen+괴리테마시작점,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
plot6(gweritem ,"괴리구간템",iff(gweritem>gweritem[1]+0.01,red,iff(gweritem<gweritem[1]-0.01,BLUE,WHITE)));
/*
PlotBaseLine1(0,"기준선");
PlotBaseLine2(1,"기준선",GRAY);
PlotBaseLine3(-1,"기준선",GRAY);
PlotBaseLine4(0.5,"기준선",BLUE);
PlotBaseLine5(-0.5,"기준선",BLUE);
*/
plot7(DayOpen+순괴리시작점,"당일시가");
if stime <= 090000 or stime >= 143000 Then
plot7(DayOpen+순괴리시작점,"당일시가",BLACK,def,0.05);#14시 이후
/*
*/
//뾰족**gweri*************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if
countif ( goldjisu[5]+0.1 <goldjisu,7) >=4
and countif ( goldjisu[1]+0.1 >goldjisu,2) >=1
//and goldjisu[1] > goldjisu
and gweri > 0.87
then{
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if
countif ( goldjisu[1]-0.15 >goldjisu,8) >=3
and countif ( goldjisu[1]-0.05 >goldjisu,7) >=2
and goldjisu[1] < goldjisu
and (goldjisu-중값)<-0.5
then{
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
/*
if countif (( gweri[1]-0.1) >gweri,4) >=4 then{
plot44(goldjisu-1,"원웨이");
}
if countif (( gweri[1]+0.1) <gweri,4) >=4 then{
plot44(goldjisu+1,"원웨이");
}
*/
//과괴리**************************************************************
/*
if dayindex > 10 and stime > 090030 and stime < 144500 then{
if ( countif (중값 >= 중값[10]+0.00 and goldjisu <goldjisu[10] - 0.1,5) >=1
and dayindex > 40)
then {
plot22(goldjisu+0.5,"기울기매도");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090000 and stime < 144500 then{
if ( countif (중값 <= 중값[10]+0.00 and goldjisu >goldjisu[10] + 0.1,5) >=1
and dayindex > 40)
then {
plot33(goldjisu-0.5,"기울기매수");
PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
//goldjisu와 가격이 0.1이탈시*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (goldjisu[1] >= 중값[1]+ 0.05,3) >=3
then{
plot22(goldjisu-0.2,"기울기매도");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if (goldjisu - h) > 0.2 then{
plot33(goldjisu+0.2,"기울기매수");
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
var : TSF(0),Period44(14);
TSF = LRL(C,Period44)+LRS(C,Period44);
Plot44(TSF,"TSF") ;
plot44(TSF,"TSF",iff(TSF>TSF[1]+0.01,red,iff(TSF<TSF[1]-0.01,BLUE,WHITE)));
//09:05이전 14:30이후 표시안보이기위함*****************************
if stime <= 090030 or stime >= 143000 Then
plot44(TSF,"TSF",BLACK,def,0.05);#14시 이후
plot66(중값,"중값",iff(중값>중값[1]+0.01,red,iff(중값<중값[1]-0.01,BLUE,WHITE)));
}
plot77(h+0.5,"고가");
plot88(l-0.5,"저가");
/*
//호가잔량큰폭2개이상*******************************************************
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif ((value[1] -value) > 300 ,3) >=3
then{
plot22(goldjisu-0.1,"기울기매도",BLUE);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
if dayindex > 10 and stime > 090100 and stime < 143000 then{
if countif (( value -value[1]) > 300 ,3) >=3
then{
plot33(goldjisu+0.2,"기울기매수",PINK);
//PlaySound("C:₩예스트레이더31₩Data₩alert.wav");
}
}
*/
중간에 짤라서 올릴 능력이안되 할수없이 그냥 올립니다 (첨부참고해주세요)
보정하면 중값과 goldjisu 를 일치시켜주세요 지금은 goldjisu가 약간 아래 있거든요
부탁드립니다
수고하세요