커뮤니티

수식 문의 드립니다.

프로필 이미지
eiger
2018-02-27 02:13:24
217
글번호 116950
답변완료

첨부 이미지

안녕하세요. 수식 문의 드립니다. 차트 30분봉 1. 이전봉이 전일 저가 위에 있을때, 전일 저가에서 매수 2. 이전봉이 전일 고가 아래에 있고, 전일 고가에서 매도 청산 30틱, 손절 20틱 [수식 시도 했으나 오류발생함] -------------------------------------------- If c[1] > daylow(1) Then { Buy("B",atstop,daylow(1)); } IF c[1]< dayhigh(1) Then { Sell("S",atstop,dayhigh(1)); } If MarketPosition == 1 Then ExitLong("EB", AtStop, EntryPrice - 20*PriceScale); If MarketPosition == -1 then ExitShort("ES", AtStop, EntryPrice + 20*PriceScale); If MarketPosition == 1 Then Exitlong("XB", atlimit, EntryPrice + 30*PriceScale); if MarketPosition == -1 Then ExitShort("XS", atlimit, EntryPrice - 30*PriceScale);
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2018-02-27 13:54:10

안녕하세요 예스스탁입니다. If MarketPosition <= 0 and L > daylow(1) Then { Buy("B",AtLimit,daylow(1)); } IF MarketPosition >= 0 and H < dayhigh(1) Then { Sell("S",AtLimit,dayhigh(1)); } If MarketPosition == 1 Then{ ExitLong("EB", AtStop, EntryPrice - 20*PriceScale); Exitlong("XB", atlimit, EntryPrice + 30*PriceScale); } if MarketPosition == -1 Then{ ExitShort("ES", AtStop, EntryPrice + 20*PriceScale); ExitShort("XS", atlimit, EntryPrice - 30*PriceScale); } 즐거운 하루되세요 > eiger 님이 쓴 글입니다. > 제목 : 수식 문의 드립니다. > 안녕하세요. 수식 문의 드립니다. 차트 30분봉 1. 이전봉이 전일 저가 위에 있을때, 전일 저가에서 매수 2. 이전봉이 전일 고가 아래에 있고, 전일 고가에서 매도 청산 30틱, 손절 20틱 [수식 시도 했으나 오류발생함] -------------------------------------------- If c[1] > daylow(1) Then { Buy("B",atstop,daylow(1)); } IF c[1]< dayhigh(1) Then { Sell("S",atstop,dayhigh(1)); } If MarketPosition == 1 Then ExitLong("EB", AtStop, EntryPrice - 20*PriceScale); If MarketPosition == -1 then ExitShort("ES", AtStop, EntryPrice + 20*PriceScale); If MarketPosition == 1 Then Exitlong("XB", atlimit, EntryPrice + 30*PriceScale); if MarketPosition == -1 Then ExitShort("XS", atlimit, EntryPrice - 30*PriceScale);