예스스탁
예스스탁 답변
2023-09-21 15:17:51
안녕하세요
예스스탁입니다.
1
input : Per1(23.6),Per2(38.2),Per3(50.0),Per4(61.8),Per5(76.4);
var : HH(0),LL(0);
input : StartTime(110000),EndTime(053000);
var : Tcond(False);
input : 익절틱수(100),손절틱수(100);
if date > date[1]+1 Then{
HH = H;
LL = L;
}
if H > HH Then
HH = H;
if L < LL Then
LL = L;
var1 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per1/100));
var2 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per2/100));
var3 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per3/100));
var4 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per4/100));
var5 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per5/100));
IF Endtime > starttime Then
SetStopEndofday(Endtime);
Else
{
if sDate != sDate[1] Then
SetStopEndofday(Endtime);
}
if (sdate != sdate[1] and stime >= EndTime) or
(sdate == sdate[1] and stime >= EndTime and stime[1] < EndTime) Then
Tcond = False;
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 Tcond == true Then
{
if CrossUp(c,Var2) Then
Buy();
if CrossUp(c,Var5) Then
ExitLong();
}
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
2
input : Per1(23.6),Per2(38.2),Per3(50.0),Per4(61.8),Per5(76.4);
var : HH(0),LL(0);
input : StartTime(110000),EndTime(053000);
var : Tcond(False);
input : 익절틱수(100),손절틱수(100);
if date > date[1]+1 Then{
HH = H;
LL = L;
}
if H > HH Then
HH = H;
if L < LL Then
LL = L;
var1 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per1/100));
var2 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per2/100));
var3 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per3/100));
var4 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per4/100));
var5 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per5/100));
IF Endtime > starttime Then
SetStopEndofday(Endtime);
Else
{
if sDate != sDate[1] Then
SetStopEndofday(Endtime);
}
if (sdate != sdate[1] and stime >= EndTime) or
(sdate == sdate[1] and stime >= EndTime and stime[1] < EndTime) Then
Tcond = False;
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 Tcond == true Then
{
if CrossDown(c,Var5) Then
Sell();
if CrossDown(c,Var2) Then
ExitShort();
}
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
3
최근 100개봉 내에서 가장최근 발생한 스윙하이를 상향돌파하면 매수
최근 100개봉 내에서 가장최근 발생한 스윙로우를 하향이탈하면 매도
즐거운 하루되세요
> 푸른 님이 쓴 글입니다.
> 제목 : 문의 드립니다
> 아래 피보나치 지표식으로 1,2번 수식어의 수정을 부탁 드립니다.
input : Per1(23.6),Per2(38.2),Per3(50.0),Per4(61.8),Per5(76.4);
var : HH(0),LL(0);
if date > date[1]+1 Then{
HH = H;
LL = L;
}
if H > HH Then
HH = H;
if L < LL Then
LL = L;
var1 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per1/100));
var2 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per2/100));
var3 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per3/100));
var4 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per4/100));
var5 = 10^(LOG10(HH)-(LOG10(HH)-LOG10(LL))*(Per5/100));
plot1(HH,"H");
plot2(var1,"23.6");
plot3(var2,"38.2");
plot4(var3,"50.0");
plot5(var4,"61.8");
plot6(var5,"76.4");
plot7(LL,"L");
1.
* 매매시간 10:00 ~ 익일 05:30
* 익절 100 손절 100
* 위의 피보나치지표 100의 변수값 23.6 매수후 76.4 청산
2.
* 매매시간 10:00 ~ 익일 05:30
* 익절 100 손절 100
* 위의 피보나치지표 100의 변수값 76.4 매도후 23.6 청산
----------------------
아래 수식의 해석을 부탁드립니다.
var1 = SwingHigh(1, H, 3, 1, 100);
var2 = SwingHigh(1, L, 3, 1, 100);
if crossup(c, var1) then{
buy();
exitshort();
}
if crossdown(c, var2) then{
sell();
exitlong();
}
Input : shortPeriod(5), longPeriod(10);
input : 익절틱수(0),손절틱수(100);
value1 = ma(C, shortPeriod);
value2 = ma(C, longPeriod);
# 매수/매도청산
If CrossUP(value1, value2) Then
{
Buy();
}
# 매도/매수청산
If CrossDown(value1, value2) Then
{
ExitLong();
}
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
Input : af(0.02), maxAF(0.2) ;
Var : value(0);
value = csar(af,maxAF);
# 매수/매도청산
If C > value Then
{
Buy();
}
# 매도/매수청산
If C < value Then
{
ExitLong();
}
Input : shortPeriod(1), longPeriod(5);
input : 익절틱수(0),손절틱수(100);
value1 = ma(C, shortPeriod);
value2 = ma(C, longPeriod);
# 매수/매도청산
If CrossDown(value2, value1) Then
{
Sell();
}
# 매도/매수청산
If CrossUP(value2, value1) Then
{
ExitShort();
}
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
var1 = SwingHigh(1, H, 3, 1, 100);
var2 = SwingHigh(1, L, 3, 1, 100);
if crossup(c, var1) then{
buy();
exitshort();
}
if crossdown(c, var2) then{
sell();
exitlong();
}
input : starttime(220000),endtime(50000),n(50);
input : 익절틱수(0),손절틱수(100);
var : Tcond(false),hh(0),h1(0),ll(0),l1(0);
IF Endtime > starttime Then
SetStopEndofday(Endtime);
Else
{
if sDate != sDate[1] Then
SetStopEndofday(Endtime);
}
if (sdate != sdate[1] and stime >= endtime) or
(sdate == sdate[1] and stime >= endtime and stime[1] < endtime) then
{
Tcond = false;
}
if (sdate != sdate[1] and stime >= starttime) or
(sdate == sdate[1] and stime >= starttime and stime[1] < starttime) then
{
Tcond = true;
hh = h;
ll = l;
h1 = hh[1];
l1 = ll[1];
IF Endtime <= starttime Then
{
SetStopEndofday(0);
}
}
if h > hh Then
hh = h;
if l < ll Then
ll = l;
if tcond == true and h1 > 0 and l1 > 0 then
{
if crossup(C,l1+(h1-l1)*1.236+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*1.000+PriceScale*n) Then
buy();
if crossup(C,l1-(h1-l1)*0.618+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*0.500+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*0.236+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*0.000+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*-0.236+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*-0.382+PriceScale*n) Then
buy();
if crossup(C,l1+(h1-l1)*-0.500+PriceScale*n) Then
buy();
}
if MarketPosition == 1 then
{
if crossup(c,h1+PriceScale*10) Then
exitlong();
if CrossDown(c,l1-PriceScale*10) Then
exitlong();
}
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);