커뮤니티

수정 부탁드립니다.

프로필 이미지
대구어린울프
2019-09-22 17:48:15
132
글번호 132144
답변완료
안녕하세요? 아래 만들어주신 수식에서, 간단한 수정 부탁드립니다. 진입신호를 살짝 고치고 싶습니다. *현재 진입신호 : 음봉+양봉에서 매수진입, 양봉+음봉에서 매도진입 *수정후 진입신호 : 양봉+양봉 에서 매수진입, 음봉+음봉에서 매도 진입 부탁드립니다. 감사합니다. ---------------------------------------------------------------------------------------- input : 매수양봉틱(5),매수음봉틱(5),매도양봉틱(5),매도음봉틱(5),진입횟수(3),갯수(5); input : 익절틱수(50),손절틱수(50); var : cnt(0); if bdate != bdate[1] Then cnt = 0; if MarketPosition != 0 and MarketPosition != MarketPosition[1] Then cnt = cnt+1; if cnt < 진입횟수 and C == O+PriceScale*매수양봉틱 and C[1] == O[1]-PriceScale*매수음봉틱 Then { if MarketPosition == 0 or (MarketPosition == -1 and BarsSinceEntry < 갯수) then buy(); } if cnt < 진입횟수 and C == O-PriceScale*매도음봉틱 and C[1] == O[1]+PriceScale*매도양봉틱 Then { if MarketPosition == 0 or (MarketPosition == 1 and BarsSinceEntry < 갯수) then sell(); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop);
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2019-09-24 12:51:40

안녕하세요 예스스탁입니다. input : 매수양봉틱(5),매수양봉틱전봉(5),매도음봉틱(5),매도음봉틱전봉(5),진입횟수(3),갯수(5); input : 익절틱수(50),손절틱수(50); var : cnt(0); if bdate != bdate[1] Then cnt = 0; if MarketPosition != 0 and MarketPosition != MarketPosition[1] Then cnt = cnt+1; if cnt < 진입횟수 and C == O+PriceScale*매수양봉틱 and C[1] == O[1]+PriceScale*매수양봉틱전봉 Then { if MarketPosition == 0 or (MarketPosition == -1 and BarsSinceEntry < 갯수) then buy(); } if cnt < 진입횟수 and C == O-PriceScale*매도음봉틱 and C[1] == O[1]-PriceScale*매도음봉틱전봉 Then { if MarketPosition == 0 or (MarketPosition == 1 and BarsSinceEntry < 갯수) then sell(); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); 즐거운 하루되세요 > 대구어린울프 님이 쓴 글입니다. > 제목 : 수정 부탁드립니다. > 안녕하세요? 아래 만들어주신 수식에서, 간단한 수정 부탁드립니다. 진입신호를 살짝 고치고 싶습니다. *현재 진입신호 : 음봉+양봉에서 매수진입, 양봉+음봉에서 매도진입 *수정후 진입신호 : 양봉+양봉 에서 매수진입, 음봉+음봉에서 매도 진입 부탁드립니다. 감사합니다. ---------------------------------------------------------------------------------------- input : 매수양봉틱(5),매수음봉틱(5),매도양봉틱(5),매도음봉틱(5),진입횟수(3),갯수(5); input : 익절틱수(50),손절틱수(50); var : cnt(0); if bdate != bdate[1] Then cnt = 0; if MarketPosition != 0 and MarketPosition != MarketPosition[1] Then cnt = cnt+1; if cnt < 진입횟수 and C == O+PriceScale*매수양봉틱 and C[1] == O[1]-PriceScale*매수음봉틱 Then { if MarketPosition == 0 or (MarketPosition == -1 and BarsSinceEntry < 갯수) then buy(); } if cnt < 진입횟수 and C == O-PriceScale*매도음봉틱 and C[1] == O[1]+PriceScale*매도양봉틱 Then { if MarketPosition == 0 or (MarketPosition == 1 and BarsSinceEntry < 갯수) then sell(); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop);