커뮤니티

문의드립니다

프로필 이미지
외국인
2011-11-19 17:34:56
515
글번호 44948
답변완료
안녕하세요 //---------------------이익실현----------------------------------- If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.04,0.25,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.05,0.35,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.07,0.5,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.05,0.7,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.02,1,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.01,1.25,PointStop); Else SetStopTrailing(0,0,0); 의 수식이 가능한지요? 위의식처럼 순서대로 SetStopTrailing이 진행 되도록 수식부탁드립니다.
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2011-11-21 09:32:49

안녕하세요 예스스탁입니다 식을 아래와 같이 풀어서 작성하셔야 합니다. if MarketPosition == 1 and stime < 150000 Then{ var1 = highest(H,BarsSinceEntry); if var1 >= EntryPrice+0.25 and var1 < EntryPrice+0.35 Then exitlong("bx1",AtStop,var1-0.04); if var1 >= EntryPrice+0.35 and var1 < EntryPrice+0.5 Then exitlong("bx2",AtStop,var1-0.05); if var1 >= EntryPrice+0.5 and var1 < EntryPrice+0.7 Then exitlong("bx3",AtStop,var1-0.07); if var1 >= EntryPrice+0.7 and var1 < EntryPrice+1 Then exitlong("bx4",AtStop,var1-0.05); if var1 >= EntryPrice+1 and var1 < EntryPrice+1.25 Then exitlong("bx5",AtStop,var1-0.02); if var1 >= EntryPrice+1.25 Then exitlong("bx6",AtStop,var1-0.01); } if MarketPosition == -1 and stime < 150000 Then{ var2 = Lowest(L,BarsSinceEntry); if var2 <= EntryPrice-0.25 and var2 > EntryPrice-0.35 Then ExitShort("sx1",AtStop,var2+0.04); if var2 <= EntryPrice-0.35 and var2 > EntryPrice-0.5 Then ExitShort("sx2",AtStop,var2+0.05); if var2 <= EntryPrice-0.5 and var2 > EntryPrice-0.7 Then ExitShort("sx3",AtStop,var2+0.07); if var2 <= EntryPrice-0.7 and var2 > EntryPrice-1 Then ExitShort("sx4",AtStop,var2+0.05); if var2 <= EntryPrice-1 and var2 > EntryPrice-1.25 Then ExitShort("sx5",AtStop,var2+0.02); if var2 <= EntryPrice-1.25 Then ExitShort("sx6",AtStop,var2+0.01); } 즐거운 하루되세요 > 외국인 님이 쓴 글입니다. > 제목 : 문의드립니다 > 안녕하세요 //---------------------이익실현----------------------------------- If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.04,0.25,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.05,0.35,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.07,0.5,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.05,0.7,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.02,1,PointStop); else If (stime >= 90000 and stime < 150000) THEN SetStopTrailing(0.01,1.25,PointStop); Else SetStopTrailing(0,0,0); 의 수식이 가능한지요? 위의식처럼 순서대로 SetStopTrailing이 진행 되도록 수식부탁드립니다.