커뮤니티
주문함수 문의..
2004-11-29 04:46:16
1205
글번호 5855
제 시스템에 주문함수를 수정할려는데 원하는 데로 되지를 않네요,,
수정좀 부탁드립니다
질문은 그림상에 올렷습니다.
--------------------------------------------------------
If marketposition() == 0 Then {
If 이평5 > 이평20 Then {
Formula0 = C > 매수기준가; // 상승추세
Formula1 = C < 매수기준가 And 음봉 ; // 하락전환
}
If 이평5 < 이평20 Then {
Formula2 = C > 매도기준가 And 양봉 ; // 상승전환
Formula3 = C < 매도기준가; // 하락추세
}
If Formula0 Then {
Buy("A",onclose,atprice); ????????????
}
If Formula1 Then {
Sell("B",onclose,atprice); ????????????
}
If Formula2 Then {
Sell("C",onclose,atprice); ????????????
}
If Formula3 Then {
Buy("D",onclose,atprice); ????????????
}
}
If marketposition() == 1 Then {
If 이평5 > 이평20 Then {
Formula4 = C < 매수기준가 And 음봉 ; //하락전환
}
If 이평5 < 이평20 Then {
Formula5 = C < 매도기준가; //하락추세
}
If Formula4 Then {
Sell("E",onclose,atprice); ????????????
}
If Formula5 Then {
Sell("F",onclose,atprice); ????????????
}
}
If marketposition() == -1 Then {
If 이평5 > 이평20 Then {
Formula6 = C > 매수기준가; // 상승추세
}
If 이평5 < 이평20 Then { // 상승전환
Formula7 = C > 매도기준가 And 양봉 ;
}
If Formula6 Then {
Buy("G",onclose,atprice); ????????????
}
If Formula7 Then {
Buy("H",onclose,atprice); ????????????
}
}
- 1. 질문.JPG (0.16 MB)
답변 1
예스스탁 예스스탁 답변
2004-11-30 09:14:10
안녕하세요
예스스탁입니다.
종가기준이 아닌 다른 가격대를 사용하시기 위해서는
atstop,atlimit 함수를 사용하시기 바랍니다.
식이 정확치 않아 정확히 어떤 가격을 사용하셨는지 알 수 없습니다.
저희홈 --> 예스트레이더프로 --> 수식작성법-->함수 및 예약어
--> 시스템함수--> 주문함수를 참고하시기 바랍니다.
즐거운 하루되세요
> 닥터파생 님이 쓴 글입니다.
> 제목 : 주문함수 문의..
> 제 시스템에 주문함수를 수정할려는데 원하는 데로 되지를 않네요,,
수정좀 부탁드립니다
질문은 그림상에 올렷습니다.
--------------------------------------------------------
If marketposition() == 0 Then {
If 이평5 > 이평20 Then {
Formula0 = C > 매수기준가; // 상승추세
Formula1 = C < 매수기준가 And 음봉 ; // 하락전환
}
If 이평5 < 이평20 Then {
Formula2 = C > 매도기준가 And 양봉 ; // 상승전환
Formula3 = C < 매도기준가; // 하락추세
}
If Formula0 Then {
Buy("A",onclose,atprice); ????????????
}
If Formula1 Then {
Sell("B",onclose,atprice); ????????????
}
If Formula2 Then {
Sell("C",onclose,atprice); ????????????
}
If Formula3 Then {
Buy("D",onclose,atprice); ????????????
}
}
If marketposition() == 1 Then {
If 이평5 > 이평20 Then {
Formula4 = C < 매수기준가 And 음봉 ; //하락전환
}
If 이평5 < 이평20 Then {
Formula5 = C < 매도기준가; //하락추세
}
If Formula4 Then {
Sell("E",onclose,atprice); ????????????
}
If Formula5 Then {
Sell("F",onclose,atprice); ????????????
}
}
If marketposition() == -1 Then {
If 이평5 > 이평20 Then {
Formula6 = C > 매수기준가; // 상승추세
}
If 이평5 < 이평20 Then { // 상승전환
Formula7 = C > 매도기준가 And 양봉 ;
}
If Formula6 Then {
Buy("G",onclose,atprice); ????????????
}
If Formula7 Then {
Buy("H",onclose,atprice); ????????????
}
}
이전글