예스스탁
예스스탁 답변
2020-01-20 09:06:01
안녕하세요
예스스탁입니다.
Input : maPeriod(20), ROCPeriod(12), stoPeriod1(5), stoPeriod2(3), sPeriod(12), IPeriod(26),sigPeriod(9);
Vars : TickSize(0),entryVol(0), ExBlockCOND(False), blockCond(True);
input : period(3);
var : haClose(0), haOpen(0), haHigh(0), haLow(0), TL1(0);
value1 = BW(maPeriod,ROCPeriod,stoPeriod1,stoPeriod2);
value2 = ema(value1,sPeriod)-ema(value1,IPeriod);
value3 = ema(value2,sigPeriod);
if CurrentBar > 1 then
{
haClose = (Open+High+Low+Close)/4;
haOpen = (haOpen[1] + haClose[1])/2 ;
haHigh = Max(High, haOpen, haClose);
haLow = Min(Low, haOpen, haClose) ;
}
if CurrentBar > 20 and ma(haClose,period) > ma(haOpen,period) Then
{
if crossup(value2,value3) then
{
buy();
}
}
즐거운 하루되세요
> 뎅이요 님이 쓴 글입니다.
> 제목 : 수식 작성 부탁 드립니다
> 아래 지표수식으로 매수 진입 조건을 설정 바랍니다
아래 매수진입 수식에 첨가 부탁 드립니다
지표수식상 plot2, plot3 의 RED 분에서만 진입이 허용(BLUE부분은 진입금지)
되도록 수식 부탁 드립니다
Input : maPeriod(20), ROCPeriod(12), stoPeriod1(5), stoPeriod2(3), sPeriod(12), IPeriod(26),sigPeriod(9);
Vars : TickSize(0);
Vars : entryVol(0), ExBlockCOND(False), blockCond(True);
value1 = BW(maPeriod,ROCPeriod,stoPeriod1,stoPeriod2);
value2 = ema(value1,sPeriod)-ema(value1,IPeriod);
value3 = ema(value2,sigPeriod);
if crossup(value2,value3) then
{
buy();
}
지표수식
input : period(3);
var : haClose(0), haOpen(0), haHigh(0), haLow(0), TL1(0);
if CurrentBar > 1 then {
haClose = (Open+High+Low+Close)/4;
haOpen = (haOpen[1] + haClose[1])/2 ;
haHigh = Max(High, haOpen, haClose);
haLow = Min(Low, haOpen, haClose) ;
}
if CurrentBar > 20 then {
if ma(haClose,period) > ma(haOpen,period) Then{
plot1((haHigh-haClose)+ma(haClose,period),"TailUp",RED);
plot2(ma(haClose,period),"BodyUP",RED);
plot3(ma(haOpen,period)-PriceScale/2 ,"BodyDelete",RGB(254,255,255));
plot4(ma(haOpen,period),"tailDown",RED);
plot5(ma(haOpen,period)-(haOpen-haLow)-PriceScale/2,"TailDelete",RGB(254,255,255));
}
else {
plot1((haHigh-haOpen)+ma(haOpen,period),"TailUp",BLUE);
plot2(ma(haOpen,period),"BodyUP",BLUE);
plot3(ma(haClose,period)-PriceScale,"BodyDelete",RGB(254,255,255));
plot4(ma(haClose,period),"tailDown",BLUE);
plot5(ma(haClose,period)-(haClose-haLow)-PriceScale/2,"TailDelete",RGB(254,255,255));
}
}