커뮤니티

수식부탁합니다

프로필 이미지
랄프
2013-06-03 11:30:06
350
글번호 63896
답변완료
안녕하세요 예스글로벌(해외선물)에 아래와 같은 이동평균 그물망지표가 있는데 수식 1 모든 이동평균선들이 예를들어 10틱(1.2000 ~ 1.2010) 범위내에서 모두 모여있들때 Plot10(ma(C,Period*10), "이동평균10"); 기준으로 진입했을시 가격이 Plot10라인 위2틱위에서 시장가로 매수 Plot10 2틱아래서 시장가로 매도진입(2개약 첫진입하고 방향대로 갔을시 1개약은5틱청산 1개약은 본청손절잡고 익절은 10틱 손절은 5틱 매매시간은 오후3시부터 새벽3시까지.... 수식2 1개약으로 가격이 Plot10라인 위2틱위에서 시장가로 매수 Plot10 2틱아래서 시장가로 매도진입 Plot10 기준으로 위 아래로 움직이면 2틱에서스위칭입니다 익절은10틱 수식 부탁드립니다 조건이 만족할때마다 진입입니다 수식3 현재가와 Plot50(ma(C,Period*50), "이동평균50");기준으로 가격이 50틱 위일때 매도 진입 가격이아래에 있을때 매수 진입 손절 10틱 익절20틱 손절시 70틱에서 다시 재진입 입니다 매매시간은 위와 같습니다 수고하세요 Input : Period(5); Plot1(ma(C,Period*1), "이동평균1"); Plot2(ma(C,Period*2), "이동평균2"); Plot3(ma(C,Period*3), "이동평균3"); Plot4(ma(C,Period*4), "이동평균4"); Plot5(ma(C,Period*5), "이동평균5"); Plot6(ma(C,Period*6), "이동평균6"); Plot7(ma(C,Period*7), "이동평균7"); Plot8(ma(C,Period*8), "이동평균8"); Plot9(ma(C,Period*9), "이동평균9"); Plot10(ma(C,Period*10), "이동평균10"); Plot11(ma(C,Period*11), "이동평균11"); Plot12(ma(C,Period*12), "이동평균12"); Plot13(ma(C,Period*13), "이동평균13"); Plot14(ma(C,Period*14), "이동평균14"); Plot15(ma(C,Period*15), "이동평균15"); Plot16(ma(C,Period*16), "이동평균16"); Plot17(ma(C,Period*17), "이동평균17"); Plot18(ma(C,Period*18), "이동평균18"); Plot19(ma(C,Period*19), "이동평균19"); Plot20(ma(C,Period*20), "이동평균20"); Plot21(ma(C,Period*21), "이동평균21"); Plot22(ma(C,Period*22), "이동평균22"); Plot23(ma(C,Period*23), "이동평균23"); Plot24(ma(C,Period*24), "이동평균24"); Plot25(ma(C,Period*25), "이동평균25"); Plot26(ma(C,Period*26), "이동평균26"); Plot27(ma(C,Period*27), "이동평균27"); Plot28(ma(C,Period*28), "이동평균28"); Plot29(ma(C,Period*29), "이동평균29"); Plot30(ma(C,Period*30), "이동평균30"); Plot31(ma(C,Period*31), "이동평균31"); Plot32(ma(C,Period*32), "이동평균32"); Plot33(ma(C,Period*33), "이동평균33"); Plot34(ma(C,Period*34), "이동평균34"); Plot35(ma(C,Period*35), "이동평균35"); Plot36(ma(C,Period*36), "이동평균36"); Plot37(ma(C,Period*37), "이동평균37"); Plot38(ma(C,Period*38), "이동평균38"); Plot39(ma(C,Period*39), "이동평균39"); Plot40(ma(C,Period*40), "이동평균30"); Plot41(ma(C,Period*41), "이동평균41"); Plot42(ma(C,Period*42), "이동평균42"); Plot43(ma(C,Period*43), "이동평균43"); Plot44(ma(C,Period*44), "이동평균44"); Plot45(ma(C,Period*45), "이동평균45"); Plot46(ma(C,Period*46), "이동평균46"); Plot47(ma(C,Period*47), "이동평균47"); Plot48(ma(C,Period*48), "이동평균48"); Plot49(ma(C,Period*49), "이동평균49"); Plot50(ma(C,Period*50), "이동평균50");
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2013-06-03 16:07:21

안녕하세요 예스스탁입니다. 1. Input : Period(5); var : cnt(0),Hmav(0),Lmav(0); Array : mav[51](0); for cnt = 1 to 50{ mav[cnt] = ma(c,Period*cnt); } var1 = ma(C,Period*10); if mav[50] > 0 Then{ Hmav = mav[1]; Lmav = mav[1]; for cnt = 1 to 50{ if mav[cnt] > Hmav Then Hmav = mav[cnt]; if mav[cnt] < Lmav Then Lmav = mav[cnt]; } if stime >= 150000 or stime < 030000 and hmav <= Lmav+PriceScale*10 Then if crossup(c,var1+PriceScale*2) Then buy("b",OnClose,def,2); if CrossDown(c,var1-PriceScale*2) Then sell("s",OnClose,def,2); } if MarketPosition == 1 Then{ exitlong("bx1",atlimit,EntryPrice+PriceScale*5,"",1,1); exitlong("bx2",atlimit,EntryPrice+PriceScale*10,"",1,1); if CurrentContracts == 1 and highest(H,BarsSinceEntry) >= EntryPrice+PriceScale*5 Then exitlong("bx3",AtStop,EntryPrice); } if MarketPosition == -1 Then{ ExitShort("sx1",atlimit,EntryPrice-PriceScale*5,"",1,1); ExitShort("sx2",atlimit,EntryPrice-PriceScale*10,"",1,1); if CurrentContracts == 1 and Lowest(L,BarsSinceEntry) <= EntryPrice-PriceScale*5 Then ExitShort("sx3",AtStop,EntryPrice); } if stime == 030000 or (stime > 030000 and stime[1] < 030000) Then{ exitlong(); ExitShort(); } 2. input : period(5); var1 = ma(C,Period*10); if crossup(c,var1+PriceScale*2) Then buy("b"); if CrossDown(c,var1-PriceScale*2) Then sell("s"); if MarketPosition == 1 Then{ exitlong("bx1",atlimit,EntryPrice+PriceScale*10); } if MarketPosition == -1 Then{ ExitShort("sx1",atlimit,EntryPrice-PriceScale*10); } 3 손절시 70틱이 위인지 아래인지 불분명합니다. 해당 내용 제외한 식입니다. Input : Period(5); var1 = ma(C,Period*50); if stime >= 150000 or stime < 030000 then{ if crossup(c,var1+PriceScale*50) Then sell("b"); if CrossDown(c,var1-PriceScale*50) Then buy("s"); } if MarketPosition == 1 Then{ exitlong("bx1",AtStop,EntryPrice-PriceScale*10); exitlong("bx2",atlimit,EntryPrice+PriceScale*20); } if MarketPosition == -1 Then{ ExitShort("sx1",AtStop,EntryPrice+PriceScale*10); ExitShort("sx2",atlimit,EntryPrice-PriceScale*20); } if stime == 030000 or (stime > 030000 and stime[1] < 030000) Then{ exitlong(); ExitShort(); } 즐거운 하루되세요 > 랄프 님이 쓴 글입니다. > 제목 : 수식부탁합니다 > 안녕하세요 예스글로벌(해외선물)에 아래와 같은 이동평균 그물망지표가 있는데 수식 1 모든 이동평균선들이 예를들어 10틱(1.2000 ~ 1.2010) 범위내에서 모두 모여있들때 Plot10(ma(C,Period*10), "이동평균10"); 기준으로 진입했을시 가격이 Plot10라인 위2틱위에서 시장가로 매수 Plot10 2틱아래서 시장가로 매도진입(2개약 첫진입하고 방향대로 갔을시 1개약은5틱청산 1개약은 본청손절잡고 익절은 10틱 손절은 5틱 매매시간은 오후3시부터 새벽3시까지.... 수식2 1개약으로 가격이 Plot10라인 위2틱위에서 시장가로 매수 Plot10 2틱아래서 시장가로 매도진입 Plot10 기준으로 위 아래로 움직이면 2틱에서스위칭입니다 익절은10틱 수식 부탁드립니다 조건이 만족할때마다 진입입니다 수식3 현재가와 Plot50(ma(C,Period*50), "이동평균50");기준으로 가격이 50틱 위일때 매도 진입 가격이아래에 있을때 매수 진입 손절 10틱 익절20틱 손절시 70틱에서 다시 재진입 입니다 매매시간은 위와 같습니다 수고하세요 Input : Period(5); Plot1(ma(C,Period*1), "이동평균1"); Plot2(ma(C,Period*2), "이동평균2"); Plot3(ma(C,Period*3), "이동평균3"); Plot4(ma(C,Period*4), "이동평균4"); Plot5(ma(C,Period*5), "이동평균5"); Plot6(ma(C,Period*6), "이동평균6"); Plot7(ma(C,Period*7), "이동평균7"); Plot8(ma(C,Period*8), "이동평균8"); Plot9(ma(C,Period*9), "이동평균9"); Plot10(ma(C,Period*10), "이동평균10"); Plot11(ma(C,Period*11), "이동평균11"); Plot12(ma(C,Period*12), "이동평균12"); Plot13(ma(C,Period*13), "이동평균13"); Plot14(ma(C,Period*14), "이동평균14"); Plot15(ma(C,Period*15), "이동평균15"); Plot16(ma(C,Period*16), "이동평균16"); Plot17(ma(C,Period*17), "이동평균17"); Plot18(ma(C,Period*18), "이동평균18"); Plot19(ma(C,Period*19), "이동평균19"); Plot20(ma(C,Period*20), "이동평균20"); Plot21(ma(C,Period*21), "이동평균21"); Plot22(ma(C,Period*22), "이동평균22"); Plot23(ma(C,Period*23), "이동평균23"); Plot24(ma(C,Period*24), "이동평균24"); Plot25(ma(C,Period*25), "이동평균25"); Plot26(ma(C,Period*26), "이동평균26"); Plot27(ma(C,Period*27), "이동평균27"); Plot28(ma(C,Period*28), "이동평균28"); Plot29(ma(C,Period*29), "이동평균29"); Plot30(ma(C,Period*30), "이동평균30"); Plot31(ma(C,Period*31), "이동평균31"); Plot32(ma(C,Period*32), "이동평균32"); Plot33(ma(C,Period*33), "이동평균33"); Plot34(ma(C,Period*34), "이동평균34"); Plot35(ma(C,Period*35), "이동평균35"); Plot36(ma(C,Period*36), "이동평균36"); Plot37(ma(C,Period*37), "이동평균37"); Plot38(ma(C,Period*38), "이동평균38"); Plot39(ma(C,Period*39), "이동평균39"); Plot40(ma(C,Period*40), "이동평균30"); Plot41(ma(C,Period*41), "이동평균41"); Plot42(ma(C,Period*42), "이동평균42"); Plot43(ma(C,Period*43), "이동평균43"); Plot44(ma(C,Period*44), "이동평균44"); Plot45(ma(C,Period*45), "이동평균45"); Plot46(ma(C,Period*46), "이동평균46"); Plot47(ma(C,Period*47), "이동평균47"); Plot48(ma(C,Period*48), "이동평균48"); Plot49(ma(C,Period*49), "이동평균49"); Plot50(ma(C,Period*50), "이동평균50");