커뮤니티

수식문의

프로필 이미지
회원
2015-01-16 15:36:41
142
글번호 82309
답변완료
매번 감사드립니다. 제가 한번 해보려고 하면 자꾸 오류가 나네요. 부탁드리겠습니다. 매수조건 atlimit문으로 부탁드리겠습니다. 과거 검증용으로 쓰려합니다. L > DayClose(1)*0.857 L < ma9*0.93 일때 저가가 ma1720*1.005 or ma2260*1.005 부분을 터치할때 매수 매도수식 손절 1.5% 매도 또는 수익 7% 매도 또는 고가가 ma9*0.995 터치할때 매도 그리고 종목검색식도 부탁드립니다. 500봉기준 전일기준 20일 평균거래대금 50억이상 저가가 3이평 -7% 지점을 터치한 종목 항상 감사합니다 주말 즐겁게 보내세요. ---------------------------------------------------------- 저번 분할매도에서 1주가 남아 시스템이 안되는 부분을 수정해주셨는데 그래도 한주가 남는데 수식은 이상없는거죠? SetStopLoss(1.4,PercentStop); if MarketPosition == 1 Then{ if CodeCategoryEx == 11 and BasePrice < 50000 Then{ xvol = int(int(MaxContracts*0.5)/10)*10; } Else{ xvol = int(MaxContracts*0.5); } exitlong("하매",AtStop,하한가); if CurrentContracts == MaxContracts Then exitlong("반매",atlimit,EntryPrice*1.03,"",max(1,xvol),1); if CurrentContracts < MaxContracts Then exitlong("완매",atlimit,EntryPrice*1.07,"",max(1,xvol),1); if MarketPosition[1] != 1 Then value1 = Didx; if sdate > EntryDate and Didx == value1+2 and stime == 144000 Then ExitLong("시간매도"); }
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2015-01-16 15:46:55

안녕하세요 예스스탁입니다. 1. var : ma9(0),ma1720(0),ma2260(0); ma9 = ma(c,9); ma1720 = ma(c,1720); ma2260 = ma(c,2260); if L > DayClose(1)*0.857 and L < ma9*0.93 then{ if L > ma1720*1.005 Then buy("b1",atlimit,ma1720*1.005); if L > ma2260*1.005 Then buy("b2",atlimit,ma2260*1.005); } if MarketPosition == 1 Then exitlong("bx",AtStop,ma9*0.995); SetStopLoss(1.6,PercentStop); SetStopProfittarget(7.0,PercentStop); 2. var1 = ma(money,20); var2 = ma(c,3); if var1[1] >= 5000000000 and crossdown(L,var2*0.97) Then find(1); 3. SetStopLoss(1.4,PercentStop); if MarketPosition == 1 Then{ if CodeCategoryEx == 11 and BasePrice < 50000 Then{ xvol = int(int(MaxContracts*0.5)/10)*10; } Else{ xvol = int(MaxContracts*0.5); } exitlong("하매",AtStop,하한가); if CurrentContracts == MaxContracts Then exitlong("반매",atlimit,EntryPrice*1.03,"",max(1,xvol),1); if CurrentContracts < MaxContracts Then exitlong("완매",atlimit,EntryPrice*1.07); if MarketPosition[1] != 1 Then value1 = Didx; if sdate > EntryDate and Didx == value1+2 and stime == 144000 Then ExitLong("시간매도"); } 기존수식은 진입수량이 25주이면 50%가 7.5이고 정수만 취해 7만 청산이 됩니다. 그러므로 반매 7, 완매 7로 됩니다. 7% 수익때 남은 물량 전량을 청산하게 수정했습니다. 즐거운 하루되세요 > HI_ki**** 님이 쓴 글입니다. > 제목 : 수식문의 > 매번 감사드립니다. 제가 한번 해보려고 하면 자꾸 오류가 나네요. 부탁드리겠습니다. 매수조건 atlimit문으로 부탁드리겠습니다. 과거 검증용으로 쓰려합니다. L > DayClose(1)*0.857 L < ma9*0.93 일때 저가가 ma1720*1.005 or ma2260*1.005 부분을 터치할때 매수 매도수식 손절 1.5% 매도 또는 수익 7% 매도 또는 고가가 ma9*0.995 터치할때 매도 그리고 종목검색식도 부탁드립니다. 500봉기준 전일기준 20일 평균거래대금 50억이상 저가가 3이평 -7% 지점을 터치한 종목 항상 감사합니다 주말 즐겁게 보내세요. ---------------------------------------------------------- 저번 분할매도에서 1주가 남아 시스템이 안되는 부분을 수정해주셨는데 그래도 한주가 남는데 수식은 이상없는거죠? SetStopLoss(1.4,PercentStop); if MarketPosition == 1 Then{ if CodeCategoryEx == 11 and BasePrice < 50000 Then{ xvol = int(int(MaxContracts*0.5)/10)*10; } Else{ xvol = int(MaxContracts*0.5); } exitlong("하매",AtStop,하한가); if CurrentContracts == MaxContracts Then exitlong("반매",atlimit,EntryPrice*1.03,"",max(1,xvol),1); if CurrentContracts < MaxContracts Then exitlong("완매",atlimit,EntryPrice*1.07,"",max(1,xvol),1); if MarketPosition[1] != 1 Then value1 = Didx; if sdate > EntryDate and Didx == value1+2 and stime == 144000 Then ExitLong("시간매도"); }