커뮤니티

확인바랍니다.

프로필 이미지
쭈니오빠
2011-12-17 18:14:24
388
글번호 45869
답변완료
신호가 이상합니다. 실시간 차트가 아닌 지나간 차트를 적용해서 그런것인지??? 최고점과 최저점내에서 가격조건에의해 매수가 이루어져야 하는데.. 범위밖에서도 매수가 발생이되고 매수발생조건이 아닌데 시가에 1.2.3차매수까지 매수가 되버리는군요. 아래 시스템식 확인바라며... 손절이후에는 매수진입금지 추가 부탁드립니다. input : 최고점(20000),최저점(10000),시작날짜(20111216); var : 중간값(0),매수1차(0),매수2차(0),매수3차(0),청산1차(0),청산2차(0); 중간값 = (최고점+최저점)/2; 매수1차 = (최고점+중간값)/2; 매수2차 = 중간값; 매수3차 = (중간값+최저점)/2; 청산1차 = (매수1차+중간값)/2; 청산2차 = (중간값+매수3차)/2; if sdate >= 시작날짜 Then{ if MarketPosition == 0 or (MarketPosition == 1 and C < EntryPrice) Then{ buy("b1",AtStop,매수1차); buy("b2",AtStop,매수2차); buy("b3",AtStop,매수3차); } if MarketPosition == 1 Then{ if CurrentEntries == MaxEntries and MaxEntries == 2 Then exitlong("bx1",atlimit,청산1차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx2",atlimit,청산2차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx3",atlimit,청산2차,"B2"); } if MarketPosition == 1 Then{ exitlong("bx4",atlimit,AvgEntryPrice*1.03,"",int(CurrentContracts*0.5),1); exitlong("bx5",atlimit,AvgEntryPrice*1.05); if crossup(C, AvgEntryPrice) Then{ Condition1 = true; var1 = index; } if Condition1 == true Then{ exitlong("bx6",AtStop,highest(H,index-var1+1)*0.99,"",int(CurrentContracts*0.5),1); exitlong("bx7",AtStop,highest(H,index-var1+1)*0.97); } exitlong("bx8",AtStop,최저점); exitlong("bx9",AtStop,AvgEntryPrice*0.95); } }
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2011-12-19 11:24:07

안녕하세요 예스스타입니다. input : 최고점(20000),최저점(10000),시작날짜(20111216); var : 중간값(0),매수1차(0),매수2차(0),매수3차(0),청산1차(0),청산2차(0); 중간값 = (최고점+최저점)/2; 매수1차 = (최고점+중간값)/2; 매수2차 = 중간값; 매수3차 = (중간값+최저점)/2; 청산1차 = (매수1차+중간값)/2; 청산2차 = (중간값+매수3차)/2; Condition1 = IsExitName("bx8",1) or IsExitName("bx9",1); if sdate >= 시작날짜 Then{ if MarketPosition == 0 or (MarketPosition == 1 and C < EntryPrice) Then{ if L > 매수1차 and Condition1 == False Then buy("b1",AtStop,매수1차); if L > 매수2차 and Condition1 == False Then buy("b2",AtStop,매수2차); if L > 매수3차 and Condition1 == False then buy("b3",AtStop,매수3차); } if MarketPosition == 1 Then{ if CurrentEntries == MaxEntries and MaxEntries == 2 Then exitlong("bx1",atlimit,청산1차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx2",atlimit,청산2차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx3",atlimit,청산2차,"B2"); } if MarketPosition == 1 Then{ exitlong("bx4",atlimit,AvgEntryPrice*1.03,"",int(CurrentContracts*0.5),1); exitlong("bx5",atlimit,AvgEntryPrice*1.05); if crossup(C, AvgEntryPrice) Then{ Condition1 = true; var1 = index; } if Condition1 == true Then{ exitlong("bx6",AtStop,highest(H,index-var1+1)*0.99,"",int(CurrentContracts*0.5),1); exitlong("bx7",AtStop,highest(H,index-var1+1)*0.97); } exitlong("bx8",AtStop,최저점); exitlong("bx9",AtStop,AvgEntryPrice*0.95); } } 즐거운 하루되세요 > 쭈니오빠 님이 쓴 글입니다. > 제목 : 확인바랍니다. > 신호가 이상합니다. 실시간 차트가 아닌 지나간 차트를 적용해서 그런것인지??? 최고점과 최저점내에서 가격조건에의해 매수가 이루어져야 하는데.. 범위밖에서도 매수가 발생이되고 매수발생조건이 아닌데 시가에 1.2.3차매수까지 매수가 되버리는군요. 아래 시스템식 확인바라며... 손절이후에는 매수진입금지 추가 부탁드립니다. input : 최고점(20000),최저점(10000),시작날짜(20111216); var : 중간값(0),매수1차(0),매수2차(0),매수3차(0),청산1차(0),청산2차(0); 중간값 = (최고점+최저점)/2; 매수1차 = (최고점+중간값)/2; 매수2차 = 중간값; 매수3차 = (중간값+최저점)/2; 청산1차 = (매수1차+중간값)/2; 청산2차 = (중간값+매수3차)/2; if sdate >= 시작날짜 Then{ if MarketPosition == 0 or (MarketPosition == 1 and C < EntryPrice) Then{ buy("b1",AtStop,매수1차); buy("b2",AtStop,매수2차); buy("b3",AtStop,매수3차); } if MarketPosition == 1 Then{ if CurrentEntries == MaxEntries and MaxEntries == 2 Then exitlong("bx1",atlimit,청산1차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx2",atlimit,청산2차,"B1"); if CurrentEntries == MaxEntries and MaxEntries == 3 Then exitlong("bx3",atlimit,청산2차,"B2"); } if MarketPosition == 1 Then{ exitlong("bx4",atlimit,AvgEntryPrice*1.03,"",int(CurrentContracts*0.5),1); exitlong("bx5",atlimit,AvgEntryPrice*1.05); if crossup(C, AvgEntryPrice) Then{ Condition1 = true; var1 = index; } if Condition1 == true Then{ exitlong("bx6",AtStop,highest(H,index-var1+1)*0.99,"",int(CurrentContracts*0.5),1); exitlong("bx7",AtStop,highest(H,index-var1+1)*0.97); } exitlong("bx8",AtStop,최저점); exitlong("bx9",AtStop,AvgEntryPrice*0.95); } }