커뮤니티
문의드립니다
2013-09-26 15:02:47
101
글번호 67867
항상 친절하게 답변해 주셔서 고맙습니다.
아래 2가지 유형에 대한 매수진입제한식을 부탁드립니다.
ㅇ 2번 연속 청산된 이익이 10%이상 일때 5일 동안 매수진입 제한
ㅇ 100봉이내에 청산이익 합이 10%이상일 때 5일 동일 매수진입 제한
수고하세요.
답변 1
예스스탁 예스스탁 답변
2013-09-26 21:27:32
안녕하세요
예스스탁입니다.
1
var : daycnt(0);
if date != date[1] Then
daycnt = daycnt+1;
var1 = PositionProfit(1)/EntryPrice(1)*100;
var2 = PositionProfit(2)/EntryPrice(2)*100;
Condition1 = (MarketPosition == 0 and TotalTrades >= 2 and (var1+var2) >= 10);
if 매수조건 Then{
if Condition1 == false Then
buy();
if Condition1 == true and daycnt > daycnt[BarsSinceExit(1)]+5 Then
buy();
}
if 매도조건 Then{
if Condition1 == false Then
sell();
if Condition1 == true and daycnt > daycnt[BarsSinceExit(1)]+5 Then
sell();
}
2.
var : daycnt(0);
if date != date[1] Then
daycnt = daycnt+1;
if BarsSinceExit(1) == 1 Then
var3 = PositionProfit(1)/EntryPrice(1)*100;
Else
var3 = 0;
Condition1 = (MarketPosition == 0 and TotalTrades >= 1 and index >= 100 and accumn(var3,100) >= 10);
if 매수조건 Then{
if Condition1 == false Then
buy();
if Condition1 == true and daycnt > daycnt[BarsSinceExit(1)]+5 Then
buy();
}
if 매도조건 Then{
if Condition1 == false Then
sell();
if Condition1 == true and daycnt > daycnt[BarsSinceExit(1)]+5 Then
sell();
}
즐거운 하루되세요
> 민기삼촌 님이 쓴 글입니다.
> 제목 : 문의드립니다
> 항상 친절하게 답변해 주셔서 고맙습니다.
아래 2가지 유형에 대한 매수진입제한식을 부탁드립니다.
ㅇ 2번 연속 청산된 이익이 10%이상 일때 5일 동안 매수진입 제한
ㅇ 100봉이내에 청산이익 합이 10%이상일 때 5일 동일 매수진입 제한
수고하세요.
다음글
이전글