커뮤니티

수정부탁합니다

프로필 이미지
상큼한아침
2012-07-03 16:19:14
305
글번호 52561
답변완료
if MarketPosition == 0 and ma(C,5) > ma(C,5)[1] and ma(C,20) > ma(C,20)[1] and Condition1 == true then buy("b1"); if MarketPosition == 1 Then{ buy("b2",atlimit,EntryPrice*0.97); buy("b3",atlimit,EntryPrice*0.94); exitlong("bx",atlimit,AvgEntryPrice*1.05); if MaxEntries == 3 and CurrentEntries == 3 Then{ exitlong("bx3",atlimit,EntryPrice*0.97); exitlong ("loss",AtStop,EntryPrice*0.91); } } 위 추가매수식에서 종가가 20 이평선 위에 있을때만 추가매수가 실행되도록 해주시고 종가가 20 이평선을 하향돌파하면 전량 매도하게 부탁합니다
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2012-07-04 16:29:15

안녕하세요 예스스탁입니다. if MarketPosition == 0 and ma(C,5) > ma(C,5)[1] and ma(C,20) > ma(C,20)[1] and Condition1 == true then buy("b1"); if MarketPosition == 1 Then{ if C > ma(c,20) Then{ buy("b2",atlimit,EntryPrice*0.97); buy("b3",atlimit,EntryPrice*0.94); } exitlong("bx",atlimit,AvgEntryPrice*1.05); if MaxEntries == 3 and CurrentEntries == 3 Then{ exitlong("bx3",atlimit,EntryPrice*0.97); exitlong ("loss",AtStop,EntryPrice*0.91); } if CrossDown(c,ma(c,20)) Then exitlong(); } 즐거운 하루되세요 > 상큼한아침 님이 쓴 글입니다. > 제목 : 수정부탁합니다 > if MarketPosition == 0 and ma(C,5) > ma(C,5)[1] and ma(C,20) > ma(C,20)[1] and Condition1 == true then buy("b1"); if MarketPosition == 1 Then{ buy("b2",atlimit,EntryPrice*0.97); buy("b3",atlimit,EntryPrice*0.94); exitlong("bx",atlimit,AvgEntryPrice*1.05); if MaxEntries == 3 and CurrentEntries == 3 Then{ exitlong("bx3",atlimit,EntryPrice*0.97); exitlong ("loss",AtStop,EntryPrice*0.91); } } 위 추가매수식에서 종가가 20 이평선 위에 있을때만 추가매수가 실행되도록 해주시고 종가가 20 이평선을 하향돌파하면 전량 매도하게 부탁합니다