커뮤니티

식 변경 부탁드립니다.

프로필 이미지
스누피독
2018-08-20 12:42:53
131
글번호 121440
답변완료
안녕하세요, 아래 식 변경하여 문의드리고자 합니다 1. 1일1진입을 삭제하고 당일청산 삭제 2. 한번 진입에서 추가로 제가 설정한 비율로 두번 더 진입할수있도록 하며(총3번진입) 설정한 비율에서 진입하면 중복진입하지 않습니다. (설정일부터 설정한 진입값 이후 추가 진입값에 도달하지못해 모두 진입하지 못하고 청산값에 도달하여도 청산, 청산이나 손절이 나오면 더이상 진입안함) 3. 청산,손절은 전량청산 4. 설정날 저점과 고점을 설정후 고점갱신이 아닌 처음 설정한 저점과고점으로 고정 (설정한 날의 당일은 분봉 고점갱신 설정되고 이후날부터 고점갱신없음 , 당일 분봉으로만 고점갱신. 후일 고점갱신없음) 위 내용 부탁드립니다. 감사합니다. --------------------------------------------------------------- input : ndate(20180601),ntime(90000),수량(1),고점(100),저점(90); input : 매매구분(1),rate(0.652),청산1(0.7),청산2(0.6),청산조건가격(0.4),손절(0.3); var : Tcond(false),HH(0),ll(0),t1(0),entrycount(0),dd(0),gap(0); if bdate != bdate[1] Then t1 = TotalTrades; if MarketPosition == 0 Then entrycount = TotalTrades-t1; Else entrycount = TotalTrades-t1+1; if sdate == ndate and stime == ntime Then { Tcond = true; hh = 고점; ll = 저점; dd = sdate; } if Tcond == true then { if sdate >= dd and H > hh Then hh = h; var1 = hh-(hh-LL)*rate; if 매매구분 == 1 and entrycount < 1 and L > var1 and stime < 144000 Then buy("b",AtLimit,var1,수량); if MarketPosition == 1 Then { gap = (EntryPrice-var1[BarsSinceEntry])/var1[BarsSinceEntry]*100; if lowest(L,BarsSinceEntry) > (hh-(hh-LL)*청산조건가격)*(1+gap/100) then ExitLong("bp1",atlimit,(hh-(hh-LL)*청산1)*(1+gap/100)); Else ExitLong("bp2",atlimit,(hh-(hh-LL)*청산2)*(1+gap/100)); ExitLong("bl",AtStop,(hh-(hh-LL)*손절)*(1+gap/100)); } } SetStopEndofday(151500);
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2018-08-20 14:51:23

안녕하세요 예스스탁입니다. 파라미딩을 다른진입신호만 허용으로 설정하고 적용하시면 됩니다. input : ndate(20180601),ntime(90000),수량(1),고점(100),저점(90); input : 매매구분(1),rate1(0.652),rate2(0.750),rate3(0.850),청산1(0.7),청산2(0.6),청산조건가격(0.4),손절(0.3); var : Tcond(false),HH(0),ll(0),t1(0),entrycount(0),dd(0),gap(0); if bdate != bdate[1] Then t1 = TotalTrades; if MarketPosition == 0 Then entrycount = TotalTrades-t1; Else entrycount = TotalTrades-t1+1; if sdate == ndate and stime == ntime Then { Tcond = true; hh = 고점; ll = 저점; dd = sdate; } if Tcond == true then { if sdate == dd and H > hh Then hh = h; var1 = hh-(hh-LL)*rate1; var2 = hh-(hh-LL)*rate1; var3 = hh-(hh-LL)*rate1; if MarketPosition == 0 and 매매구분 == 1 and L > var1 and stime < 144000 Then buy("b1",AtLimit,var1,수량); if MarketPosition == 1 Then { if MaxEntries == 1 and L > var2 and stime < 144000 Then buy("b2",AtLimit,var2,수량); if MaxEntries == 2 and L > var3 and stime < 144000 Then buy("b3",AtLimit,var3,수량); gap = (EntryPrice-var1[BarsSinceEntry])/var1[BarsSinceEntry]*100; if lowest(L,BarsSinceEntry) > (hh-(hh-LL)*청산조건가격)*(1+gap/100) then ExitLong("bp1",atlimit,(hh-(hh-LL)*청산1)*(1+gap/100)); Else ExitLong("bp2",atlimit,(hh-(hh-LL)*청산2)*(1+gap/100)); ExitLong("bl",AtStop,(hh-(hh-LL)*손절)*(1+gap/100)); } } 즐거운 하루되세요 > 스누피독 님이 쓴 글입니다. > 제목 : 식 변경 부탁드립니다. > 안녕하세요, 아래 식 변경하여 문의드리고자 합니다 1. 1일1진입을 삭제하고 당일청산 삭제 2. 한번 진입에서 추가로 제가 설정한 비율로 두번 더 진입할수있도록 하며(총3번진입) 설정한 비율에서 진입하면 중복진입하지 않습니다. (설정일부터 설정한 진입값 이후 추가 진입값에 도달하지못해 모두 진입하지 못하고 청산값에 도달하여도 청산, 청산이나 손절이 나오면 더이상 진입안함) 3. 청산,손절은 전량청산 4. 설정날 저점과 고점을 설정후 고점갱신이 아닌 처음 설정한 저점과고점으로 고정 (설정한 날의 당일은 분봉 고점갱신 설정되고 이후날부터 고점갱신없음 , 당일 분봉으로만 고점갱신. 후일 고점갱신없음) 위 내용 부탁드립니다. 감사합니다. --------------------------------------------------------------- input : ndate(20180601),ntime(90000),수량(1),고점(100),저점(90); input : 매매구분(1),rate(0.652),청산1(0.7),청산2(0.6),청산조건가격(0.4),손절(0.3); var : Tcond(false),HH(0),ll(0),t1(0),entrycount(0),dd(0),gap(0); if bdate != bdate[1] Then t1 = TotalTrades; if MarketPosition == 0 Then entrycount = TotalTrades-t1; Else entrycount = TotalTrades-t1+1; if sdate == ndate and stime == ntime Then { Tcond = true; hh = 고점; ll = 저점; dd = sdate; } if Tcond == true then { if sdate >= dd and H > hh Then hh = h; var1 = hh-(hh-LL)*rate; if 매매구분 == 1 and entrycount < 1 and L > var1 and stime < 144000 Then buy("b",AtLimit,var1,수량); if MarketPosition == 1 Then { gap = (EntryPrice-var1[BarsSinceEntry])/var1[BarsSinceEntry]*100; if lowest(L,BarsSinceEntry) > (hh-(hh-LL)*청산조건가격)*(1+gap/100) then ExitLong("bp1",atlimit,(hh-(hh-LL)*청산1)*(1+gap/100)); Else ExitLong("bp2",atlimit,(hh-(hh-LL)*청산2)*(1+gap/100)); ExitLong("bl",AtStop,(hh-(hh-LL)*손절)*(1+gap/100)); } } SetStopEndofday(151500);