커뮤니티

SetStopLoss 관한 질문을 하려고 합니다.

프로필 이미지
kaiyora
2015-01-22 09:05:50
177
글번호 82489
답변완료
안녕하세요. 아래 예문을 보시고 제 질문에 답변 주세요. SetStopLoss(손절매값,Method); 관한 질문을 하려고 합니다. 예제 var : cnt(0); if date != date[1] then cnt = 0; if stime >= 093000 and cnt == 0 then { if CrossUp(C, timehigh(090000, 092959)) then { buy(); cnt = cnt + 1; } if CrossDown(C, timelow(090000, 092959)) then { sell(); cnt = cnt + 1; } } SetStopLoss(PriceScale*30,PointStop); ________________________________________________________________________________________ SetStopLoss(손절매값,Method); 관한 질문을 하려고 합니다. 1.질문 SetStopLoss(PriceScale*10,PointStop);를 예) SetStopLoss(Dayopen*30,PointStop); 변경해 위와 같이 Dayopen(시가)를 사용해 즉 포지션이 매수 또는 매도 주문에서 StopLoss를 Dayopen 에서 30Point를 사용할 수 있을까요? 시스템에서 매수 또는 매도주문이 나가고 시가에서 30Point를 StopLoss로 사용할려면 어 떻게 해야하나요? 2.질문 if CrossUp(C, timehigh(090000, 092959)) then { buy(); 주문에서 09시에서 09시30분 사이에 저가인 timelow를 사용해 StopLoss를 사용하려면, SetStopLoss(timelow*10,PointStop); 식으로 변경해서 사용이 안되나요? 위의 예제에서 09~09:30 에서 만들어진 timehight 또는 timelow를 사용해 SetStopLoss 시스템을 작성하려면 어떻게 해야하나요? 예) SetStopLoss(timehigh*10,PointStop); 위의 식이 가능 할까요?
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2015-01-22 14:33:38

안녕하세요 예스스탁입니다. 강제청산는 모두 entryprice가 기준입니다. 시초가나 다른 가격을 기준으로 하시면 따로 풀어서 작성하셔야 합니다. 1. #매수진입후 시초가에서 30포인트 하락하면 청산 if MarketPosition == 1 Then ExitLong("bx",AtStop,dayopen-30); #매도진입후 시초가에서 30포인트 상승하면 청산 if MarketPosition == -1 Then ExitShort("sx",AtStop,dayopen+30); 30포인트 가이고 30틱이시면 아래와 같이 작성하시면 됩니다. #매수진입후 시초가에서 30틱 하락하면 청산 if MarketPosition == 1 Then ExitLong("bx",AtStop,dayopen-PriceScale*30); #매도진입후 시초가에서 30포인트 상승하면 청산 if MarketPosition == -1 Then ExitShort("sx",AtStop,dayopen+PriceScale*30); 2 30포인트 if MarketPosition == 1 Then ExitLong("bx",AtStop,timehigh(090000, 092959)-30); if MarketPosition == -1 Then ExitShort("sx",AtStop,TimeLow(090000, 092959)+30); 30틱 if MarketPosition == 1 Then ExitLong("bx",AtStop,timehigh(090000, 092959)-PriceScale*30); if MarketPosition == -1 Then ExitShort("sx",AtStop,TimeLow(090000, 092959)+PriceScale*30); 즐거운 하루되세요 > kaiyora 님이 쓴 글입니다. > 제목 : SetStopLoss 관한 질문을 하려고 합니다. > 안녕하세요. 아래 예문을 보시고 제 질문에 답변 주세요. SetStopLoss(손절매값,Method); 관한 질문을 하려고 합니다. 예제 var : cnt(0); if date != date[1] then cnt = 0; if stime >= 093000 and cnt == 0 then { if CrossUp(C, timehigh(090000, 092959)) then { buy(); cnt = cnt + 1; } if CrossDown(C, timelow(090000, 092959)) then { sell(); cnt = cnt + 1; } } SetStopLoss(PriceScale*30,PointStop); ________________________________________________________________________________________ SetStopLoss(손절매값,Method); 관한 질문을 하려고 합니다. 1.질문 SetStopLoss(PriceScale*10,PointStop);를 예) SetStopLoss(Dayopen*30,PointStop); 변경해 위와 같이 Dayopen(시가)를 사용해 즉 포지션이 매수 또는 매도 주문에서 StopLoss를 Dayopen 에서 30Point를 사용할 수 있을까요? 시스템에서 매수 또는 매도주문이 나가고 시가에서 30Point를 StopLoss로 사용할려면 어 떻게 해야하나요? 2.질문 if CrossUp(C, timehigh(090000, 092959)) then { buy(); 주문에서 09시에서 09시30분 사이에 저가인 timelow를 사용해 StopLoss를 사용하려면, SetStopLoss(timelow*10,PointStop); 식으로 변경해서 사용이 안되나요? 위의 예제에서 09~09:30 에서 만들어진 timehight 또는 timelow를 사용해 SetStopLoss 시스템을 작성하려면 어떻게 해야하나요? 예) SetStopLoss(timehigh*10,PointStop); 위의 식이 가능 할까요?