커뮤니티

부탁합니다

프로필 이미지
미래테크
2013-10-14 11:39:25
150
글번호 68409
답변완료
주가가 5일선 Crossdown 발생시 분할 매수하는 시스템식 부탁합니다 매수식 매수금액 천만원 매수비중 50% 예를 들어 A라는 종목이 Crossdown 발생시 주가가 5000원 일때 5000원 부터 아래로 한호가씩 4호가에 나눠서 호가당 같은 비중으로 분할 매수하는 시스템식 부탁합니다 A 종목 매수금액 500만원 매수단가는 5000원 4990 4980 4970 이렇게 한호가씩 4번에 걸쳐서 매수나가는 시스템식 부탁합니다 매도식은 분할 매수한 평균매수단가를 구하고 1차매도 4.5% 수익시 40% 2차매도 6.5% 수익시 30% 3차매도 8.5% 수익시 잔량 매도 손절은 3%
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2013-10-14 17:16:14

안녕하세요 예스스탁입니다. 피라미딩을 다른진입신호만 허용으로 설정하시고 적용하시기 바랍니다. input : 투자금액(1000000),진입당비중(20); var : Vol(0),xvol1(0),xvol2(0); if CodeCategoryEx == 11 and BasePrice < 50000 Then vol = int(int((투자금액*(진입당비중/100))/C)/10)*10; Else vol = int((투자금액*(진입당비중/100))/C); if MarketPosition == 0 and crossup(c,ma(C,5)) Then{ buy("b1",OnClose,def,Vol); buy("b2",AtLimit,c-PriceScale*1,Vol); buy("b3",AtLimit,c-PriceScale*2,Vol); buy("b4",AtLimit,c-PriceScale*3,Vol); buy("b5",AtLimit,c-PriceScale*4,Vol); } if MarketPosition == 1 and countif(CurrentContracts < CurrentContracts[1],BarsSinceEntry) < 1 Then{ if Lowest(L,BarsSinceEntry) > EntryPrice-PriceScale*1 Then buy("b21",atlimit,EntryPrice-PriceScale*1); if Lowest(L,BarsSinceEntry) > EntryPrice-PriceScale*2 Then buy("b31",atlimit,EntryPrice-PriceScale*2); if Lowest(L,BarsSinceEntry) > EntryPrice-PriceScale*3 Then buy("b41",atlimit,EntryPrice-PriceScale*3); if Lowest(L,BarsSinceEntry) > EntryPrice-PriceScale*4 Then buy("b51",atlimit,EntryPrice-PriceScale*4); } if MarketPosition == 1 Then{ if CodeCategoryEx == 11 and BasePrice < 50000 Then{ xvol1 = int(int(MaxContracts*0.4)/10)*10; xvol2 = int(int(MaxContracts*0.3)/10)*10; } Else{ xvol1 = int(MaxContracts*0.4); xvol2 = int(MaxContracts*0.3); } if CurrentContracts == MaxContracts Then ExitLong("bx1",atlimit,AvgEntryPrice*1.045,"",xvol1,1); if CurrentContracts < MaxContracts Then{ if countif(CurrentContracts < CurrentContracts[1],BarsSinceEntry) == 1 Then ExitLong("bx2",atlimit,AvgEntryPrice*1.065,"",xvol2,1); if countif(CurrentContracts < CurrentContracts[1],BarsSinceEntry) == 2 Then ExitLong("bx3",atlimit,AvgEntryPrice*1.085); } ExitLong("losscut",AtStop,AvgEntryPrice*0.97); } 즐거운 하루되세요 > 미래테크 님이 쓴 글입니다. > 제목 : 부탁합니다 > 주가가 5일선 Crossdown 발생시 분할 매수하는 시스템식 부탁합니다 매수식 매수금액 천만원 매수비중 50% 예를 들어 A라는 종목이 Crossdown 발생시 주가가 5000원 일때 5000원 부터 아래로 한호가씩 4호가에 나눠서 호가당 같은 비중으로 분할 매수하는 시스템식 부탁합니다 A 종목 매수금액 500만원 매수단가는 5000원 4990 4980 4970 이렇게 한호가씩 4번에 걸쳐서 매수나가는 시스템식 부탁합니다 매도식은 분할 매수한 평균매수단가를 구하고 1차매도 4.5% 수익시 40% 2차매도 6.5% 수익시 30% 3차매도 8.5% 수익시 잔량 매도 손절은 3%