항상 도움 주셔서 감사드립니다.
선물 3분봉 기준으로
condition1 = 위로 3틱 안에 피봇저항선(분봉 피봇-1,2,3차 모두 포함)이 있다;
condition2 = 아래로 3틱 안에 피봇저항선(분봉 피봇-1,2,3차 모두 포함)이 있다;
condition3 = 현재봉 기준 전봉 10봉(C[10]) 이내에 20,60선이 골든크로스가 있다;
condition4 = 현재봉 기준 전봉 10봉(C[10]) 이내에 20,60선이 데드크로스가 있다;
if 조건 and (( condition1==false or (condition1==true and condition3==true))
then buy ();
진입 조건이 맞아도 3틱(위)이내에 분봉 피봇이 있으면 진입하지 마라. 단 10봉 이내에
20,60골든크로스가 있다면 진입하라.
if 조건 and (( condition2==false or (condition2==true and condition4==true))
then sell ();
매수와 같은 조건 입니다. 도움 부탁드립니다.
답변 1
예스스탁
예스스탁 답변
2023-07-17 14:47:14
안녕하세요
예스스탁입니다.
Var : PP(0), R3(0),R2(0), R1(0), S1(0), S2(0), S3(0);
var : mav1(0),mav2(0);
PP = ( dayhigh(1) + dayclose(1) + daylow(1) )/3;
R3 = dayhigh(1) + 2*(PP - daylow(1));
R2 = PP+dayhigh(1)-daylow(1);
R1 = 2 * PP - daylow(1);
S1 = 2 * PP - dayhigh(1);
S2 = PP-dayhigh(1)+daylow(1);
S3 = daylow(1) - 2*(dayhigh(1) - PP);
mav1 = ma(C,20);
mav2 = ma(C,60);
Condition1 = max(R1,R2,R3) <= C+PriceScale*3;
Condition2 = min(S1,S2,S3) >= C-PriceScale*3;
Condition3 = countif(CrossUp(mav1,mav2),10) >= 1;
Condition3 = countif(CrossDown(mav1,mav2),10) >= 1;
if 조건 and (condition1==false or (condition1==true and condition3==true))
then buy ();
if 조건 and (condition2==false or (condition2==true and condition4==true))
then sell ();
즐거운 하루되세요
> 비정성시 님이 쓴 글입니다.
> 제목 : 수식 부탁드립니다.
> 항상 도움 주셔서 감사드립니다.
선물 3분봉 기준으로
condition1 = 위로 3틱 안에 피봇저항선(분봉 피봇-1,2,3차 모두 포함)이 있다;
condition2 = 아래로 3틱 안에 피봇저항선(분봉 피봇-1,2,3차 모두 포함)이 있다;
condition3 = 현재봉 기준 전봉 10봉(C[10]) 이내에 20,60선이 골든크로스가 있다;
condition4 = 현재봉 기준 전봉 10봉(C[10]) 이내에 20,60선이 데드크로스가 있다;
if 조건 and (( condition1==false or (condition1==true and condition3==true))
then buy ();
진입 조건이 맞아도 3틱(위)이내에 분봉 피봇이 있으면 진입하지 마라. 단 10봉 이내에
20,60골든크로스가 있다면 진입하라.
if 조건 and (( condition2==false or (condition2==true and condition4==true))
then sell ();
매수와 같은 조건 입니다. 도움 부탁드립니다.