커뮤니티
시스템식이 안되네요
2011-04-26 17:52:20
616
글번호 37986
풋매수는되는데 풋매수청산이안되고요
콜도 동일 청산이안됨니다
매수전용 계좌인경우임 참조바람니다.
매수후 매도만가능함
va1 = ma(c,5);
va2 = ma(c,20);
선물을이용해서 콜옵션거래 풋옵션거래 신호미완성즉시매수매도될수있도록 부탁드림니다.
//1.매수후3개봉이내에서 매도금지
//2.매도후3개봉이내에서 매수금지
장2시45분 청산
감사합니다
선물을 이용해서 콜과 풋을 거래하셔야 하므로
주종목이 콜이나 풋이 되어야 합니다.
1. 콜
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = ma(c,5);
va2 = ma(c,20);
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossup(va1,va2) and cnt < 1) then{
buy("매수");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
buy("매수1");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
ExitLong("청산2");
}
}
if (BarsSinceEntry() > 3 and crossdown(va1,va2)) or data2(stime == 150000) then
exitlong("매수청산1");
2. 풋
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = ma(c,5);
va2 = ma(c,20);
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossdown(va1,va2) and cnt < 1) then{
buy("매수");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
buy("매도1");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
ExitLong("매수2");
}
}
if (BarsSinceEntry() > 3 and crossup(va1,va2)) or data2(stime == 150000) then
ExitLong("매도청산");
답변 1
예스스탁 예스스탁 답변
2011-04-26 18:16:03
안녕하세요
예스스탁입니다.
식을 수정했습니다.
1. 콜
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = data2(ma(c,5));
va2 = data2(ma(c,20));
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossup(va1,va2) and cnt < 1) then{
buy("매수");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
buy("매수1");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
ExitLong("청산2");
}
}
if (BarsSinceEntry() > 3 and crossdown(va1,va2)) or data2(stime == 150000) then
exitlong("매수청산1");
2, 풋
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = data2(ma(c,5));
va2 = data2(ma(c,20));
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossdown(va1,va2) and cnt < 1) then{
buy("매수1");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
buy("매수2");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
ExitLong("매수청산1");
}
}
if (BarsSinceEntry() > 3 and crossup(va1,va2)) or data2(stime == 150000) then
ExitLong("매수청산2");
즐거운 하루되세요
> 외국인 님이 쓴 글입니다.
> 제목 : 시스템식이 안되네요
> 풋매수는되는데 풋매수청산이안되고요
콜도 동일 청산이안됨니다
매수전용 계좌인경우임 참조바람니다.
매수후 매도만가능함
va1 = ma(c,5);
va2 = ma(c,20);
선물을이용해서 콜옵션거래 풋옵션거래 신호미완성즉시매수매도될수있도록 부탁드림니다.
//1.매수후3개봉이내에서 매도금지
//2.매도후3개봉이내에서 매수금지
장2시45분 청산
감사합니다
선물을 이용해서 콜과 풋을 거래하셔야 하므로
주종목이 콜이나 풋이 되어야 합니다.
1. 콜
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = ma(c,5);
va2 = ma(c,20);
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossup(va1,va2) and cnt < 1) then{
buy("매수");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
buy("매수1");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
ExitLong("청산2");
}
}
if (BarsSinceEntry() > 3 and crossdown(va1,va2)) or data2(stime == 150000) then
exitlong("매수청산1");
2. 풋
var : va1(0,data2),va2(0,data2),cnt(0);
va1 = ma(c,5);
va2 = ma(c,20);
if data2(date != date[1]) then
cnt = 0;
if data2(stime >= 90000 and stime < 150000) then{
if data2(crossdown(va1,va2) and cnt < 1) then{
buy("매수");
cnt = 1;
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossdown(va1,va2)) then{
buy("매도1");
}
if data2(cnt == 1 and BarsSinceEntry() > 3 and crossup(va1,va2)) then{
ExitLong("매수2");
}
}
if (BarsSinceEntry() > 3 and crossup(va1,va2)) or data2(stime == 150000) then
ExitLong("매도청산");