커뮤니티

시스템식질문입니다

프로필 이미지
파인애플
2014-02-26 21:36:10
154
글번호 72949
답변완료
1 1틱차트에서 조건1의 만족하고 1초 마다 1계약씩 N계약까지 분할 진입 조건2를 만족하고 1초 마다 1계약씩 N계약까지 분할 청산하는 식을 만들고 싶습니다 2 1틱차트에서 조건1의 만족하고 50틱 마다 1계약씩 N계약까지 분할 진입 조건2를 만족하고 50틱 마다 1계약씩 N계약까지 분할 청산하는 식을 만들고 싶습니다
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2014-02-27 16:48:38

안녕하세용 예스스탁입니다. 1. input : N(10); if date != date[1] Then{ Condition1 = false; Condition2 = false; } if Condition1 == false and 조건1 Then{ Condition1 = true; } if MarketPosition >= 0 and Condition1 == true and stime > stime[1] and CurrentContracts < N Then buy("b",OnClose,def,1); if MarketPosition == 1 Then{ if 조건2 Then Condition2 = true; if Condition2 == true Then ExitLong("bx",OnClose,def,"",1,1); } 2. input : N(10); var : BT(0),XT(0); if date != date[1] Then{ Condition1 = false; Condition2 = false; } if Condition1 == false and 조건1 Then{ Condition1 = true; var1 = dayindex; } if Condition1 == true Then{ BT = (dayindex-var1)%50; if MarketPosition >= 0 and BT == 0 and CurrentContracts < N Then buy("b",OnClose,def,1); } if MarketPosition == 1 Then{ if 조건2 Then{ Condition2 = true; var2 = dayindex; } if Condition2 == true Then{ XT = (dayindex-var2)%50; if XT == 0 Then ExitLong("bx",OnClose,def,"",1,1); } } 즐거운 하루되세요 > 파인애플 님이 쓴 글입니다. > 제목 : 시스템식질문입니다 > 1 1틱차트에서 조건1의 만족하고 1초 마다 1계약씩 N계약까지 분할 진입 조건2를 만족하고 1초 마다 1계약씩 N계약까지 분할 청산하는 식을 만들고 싶습니다 2 1틱차트에서 조건1의 만족하고 50틱 마다 1계약씩 N계약까지 분할 진입 조건2를 만족하고 50틱 마다 1계약씩 N계약까지 분할 청산하는 식을 만들고 싶습니다