커뮤니티
문의드립니다
2013-11-15 17:35:24
157
글번호 69547
[ 기존수식]
input : BBP(20),dv(2);
var : BBup(0),BBdn(0);
BBup = BollBandUp(BBP,dv);
BBdn = BollBandDown(BBp,Dv);
if C > O and C <= BBdn Then
var1 = 1;
if MarketPosition == 0 or C <= BBdn Then{
var1 = 2;
Buy("매수");
}
if C < O and BBUp>= C Then
var1 = -1;
if MarketPosition == 0 or C >= BBup Then{
var1 = -2;
sell("매도");
}
if MarketPosition == 1 Then{
if countif(C<O,3) == 3 and C < EntryPrice Then
ExitLong();
if stime == 150000 and C <= EntryPrice-0.5 Then
ExitLong();
}
if MarketPosition == -1 Then{
if countif(C>O,3) == 3 and C > EntryPrice Then
ExitShort();
if stime == 150000 and C >= EntryPrice+0.5 Then
ExitShort();
}
위 수식에서
신호발생 봉에서 지표상 거래대금(전일비교)이 10,000 이상 또는
직전봉대비 거래대금이 500%이상 높을경우 하나라도 해당될때 신호 진입하고,
반대의 경우는 신호 집입 금지로 수정좀 부탁드립니다.
답변 1
예스스탁 예스스탁 답변
2013-11-18 09:48:05
안녕하세요
예스스탁입니다.
input : BBP(20),dv(2),Per(500);
var : BBup(0),BBdn(0);
BBup = BollBandUp(BBP,dv);
BBdn = BollBandDown(BBp,Dv);
if C > O and C <= BBdn Then
var1 = 1;
if (MarketPosition == 0 or C <= BBdn) And (money >= 10000 or (money >= Money[1]*(1+Per/100))) Then{
var1 = 2;
Buy("매수");
}
if C < O and BBUp>= C Then
var1 = -1;
if (MarketPosition == 0 or C >= BBup) and (money >= 10000 or (money >= Money[1]*(1+Per/100))) Then{
var1 = -2;
sell("매도");
}
if MarketPosition == 1 Then{
if countif(C<O,3) == 3 and C < EntryPrice Then
ExitLong();
if stime == 150000 and C <= EntryPrice-0.5 Then
ExitLong();
}
if MarketPosition == -1 Then{
if countif(C>O,3) == 3 and C > EntryPrice Then
ExitShort();
if stime == 150000 and C >= EntryPrice+0.5 Then
ExitShort();
}
즐거운 하루되세요
> 칼봉산 님이 쓴 글입니다.
> 제목 : 문의드립니다
> [ 기존수식]
input : BBP(20),dv(2);
var : BBup(0),BBdn(0);
BBup = BollBandUp(BBP,dv);
BBdn = BollBandDown(BBp,Dv);
if C > O and C <= BBdn Then
var1 = 1;
if MarketPosition == 0 or C <= BBdn Then{
var1 = 2;
Buy("매수");
}
if C < O and BBUp>= C Then
var1 = -1;
if MarketPosition == 0 or C >= BBup Then{
var1 = -2;
sell("매도");
}
if MarketPosition == 1 Then{
if countif(C<O,3) == 3 and C < EntryPrice Then
ExitLong();
if stime == 150000 and C <= EntryPrice-0.5 Then
ExitLong();
}
if MarketPosition == -1 Then{
if countif(C>O,3) == 3 and C > EntryPrice Then
ExitShort();
if stime == 150000 and C >= EntryPrice+0.5 Then
ExitShort();
}
위 수식에서
신호발생 봉에서 지표상 거래대금(전일비교)이 10,000 이상 또는
직전봉대비 거래대금이 500%이상 높을경우 하나라도 해당될때 신호 진입하고,
반대의 경우는 신호 집입 금지로 수정좀 부탁드립니다.