커뮤니티
문의드립니다 감사합니다
2017-04-28 14:06:19
109
글번호 109267
두번째 신호부터 진입하고 싶습니다 첫번째 크로스는 진입하지 않고요
감사합니다
input : Period(1),당일청산시간(142000),스탑(0.35),시작시간(090300);
var : value1(0),value6(0,data2),value7(0,data3),value3(0),value8(0,data4),value9(0,data5),value5(0),tcond(False),count(0),value10(0);
# 당일진입횟수계산
count = 0 ;
for value1 = 0 to 10 {
if entrydate(value1) == date then
count = count + 1 ;
}
value3 = data2(C)-data3(C);
Value1 = data2(C)/data3(C)*100;
value5 = data4(C)/data5(C)*100;
if stime == 시작시간 or (stime > 시작시간 and stime[1] < 시작시간) Then
tcond = true;
if stime == 당일청산시간 or (stime > 당일청산시간 and stime[1] < 당일청산시간) Then
tcond = False;
if tcond == true and count < 3 then {
if CrossDown(value1,200) Then
sell();
if Crossup(value1,50) Then
buy();
}
답변 1
예스스탁 예스스탁 답변
2017-04-28 14:27:54
안녕하세요
예스스탁입니다.
input : Period(1),당일청산시간(142000),스탑(0.35),시작시간(090300);
var : value1(0),value6(0,data2),value7(0,data3),value3(0),value8(0,data4),value9(0,data5),value5(0),tcond(False),count(0),value10(0);
var : cnt(0,data1);
# 당일진입횟수계산
count = 0 ;
for value1 = 0 to 10 {
if entrydate(value1) == date then
count = count + 1 ;
}
value3 = data2(C)-data3(C);
Value1 = data2(C)/data3(C)*100;
value5 = data4(C)/data5(C)*100;
if stime == 시작시간 or (stime > 시작시간 and stime[1] < 시작시간) Then {
tcond = true;
cnt = 0;
}
if stime == 당일청산시간 or (stime > 당일청산시간 and stime[1] < 당일청산시간) Then
tcond = False;
if tcond == true and count < 3 then {
if CrossDown(value1,200) Then{
cnt = cnt+1;
if cnt >= 2 then
sell();
}
if Crossup(value1,50) Then{
cnt = cnt+1;
if cnt >= 2 then
buy();
}
}
즐거운 하루되세요
> 비상8 님이 쓴 글입니다.
> 제목 : 문의드립니다 감사합니다
> 두번째 신호부터 진입하고 싶습니다 첫번째 크로스는 진입하지 않고요
감사합니다
input : Period(1),당일청산시간(142000),스탑(0.35),시작시간(090300);
var : value1(0),value6(0,data2),value7(0,data3),value3(0),value8(0,data4),value9(0,data5),value5(0),tcond(False),count(0),value10(0);
# 당일진입횟수계산
count = 0 ;
for value1 = 0 to 10 {
if entrydate(value1) == date then
count = count + 1 ;
}
value3 = data2(C)-data3(C);
Value1 = data2(C)/data3(C)*100;
value5 = data4(C)/data5(C)*100;
if stime == 시작시간 or (stime > 시작시간 and stime[1] < 시작시간) Then
tcond = true;
if stime == 당일청산시간 or (stime > 당일청산시간 and stime[1] < 당일청산시간) Then
tcond = False;
if tcond == true and count < 3 then {
if CrossDown(value1,200) Then
sell();
if Crossup(value1,50) Then
buy();
}