답변완료
수식 부탁드립니다.
더운데 고생많으십니다.
아래 수식은 키움증권수식입니다..
YesTrader 수식으로 변환 부탁드립니다.
1.
a=(o(1)+c(1))/2;
o(2)<c(2)and crossdown(c,a)
2.기간 60, 종류 가중
수식1: ma(c,기간,종류);
수식2: A=ma(c,기간,종류);
if(A>A(1)*(1+PT()/1000), A, 0)
수식3: A=ma(c,기간,종류);
if(A<A(1)*(1-PT()/1000), A, 0)
수식4: A=ma(c,기간,종류);
if(A<=A(1)*(1+PT()/1000) && A>=A(1)*(1-PT()/1000),A,0)
3.기간 60, 종류 단순
수식1: ma(c,기간,종류)
수식2: m=ma(c,기간,종류);
valuewhen(1, m<m(1),m)
4.기간 60, 종류 단순
수식1: ma(c,기간,종류)
수식2: m=ma(c,기간,종류);
valuewhen(1, m>m(1),m)
5.기간60, 종류 단순, 비율 0.02
수식1: a=ma(c,기간,종류);
if(a>a(1),a,0)
수식2: a=ma(c,기간,종류);
if(a<a(1),a,0)
수식3: a=ma(c,기간,종류);
if(a<a(1)*(1+비율/100)and a>a(1)*(1-비율/100),a,0)
2022-07-18
1679
글번호 160815
지표
답변완료
지그재그 재질문
안녕하세요! 이전 답변에 대한 재질문 입니다.
혹시 그럼 힌트 하나만 주실 수 있을까요? 함수 작성은 제가 직접 하겠습니다.(주봉,월봉 작성 법은 알고있습니다)
항상 도움주셔서 감사드립니다^^
//////////////////////////////////////////////////////
안녕하세요
예스스탁입니다.
문의하신 내용은 수식으로 가능한 내용이지만
작성해 보는데 시간이 많이 소모되는 내용으로 저희가 답변을 드리기 어렵습니다.
업무상 일정시간 이상 요구되는 내용은 저희가 답변을 드리지 않습니다.
도움을 드리지 못해 죄송합니다.
즐거운 하루되세요
> 히익 님이 쓴 글입니다.
> 제목 : 지그재그 차트
> 안녕하세요 개발자님. 첨부된 사진은 예전에 개발자님께서 작성해주신 지그재그 차트입니다. 주봉에 적용되었고, length(기간) 은 2 입니다.
혹시 이 주봉에 적용된 지그재그 차트와 함수를 일봉에 그대로 옮겨와 적용시키는게 가능할까요?
아래는 지그재그 함수 입니다. 항상 도움 주셔서 감사합니다!
input:length(12);
Var:j(0),lastHiVal(0),lastLoVal(0),sBar(0),eBar(0),TL1(0),Text1(0),process(0),T(0);
Array:HH[10,2](0),LL[10,2](0);
process = 0;
If Highest(H,length) == H and lastHiVal <> H and Lowest(L,length) == L and lastLoVal <> L Then
{
If LL[1,1] > L Then process = -1;
If HH[1,1] < H Then process = 1;
}
Else If Highest(H,length) == H and lastHiVal <> H Then process = 1;
Else If Lowest(L,length) == L and lastLoVal <> L Then process = -1;
If process == 1 Then
{
T = 1;
lastHiVal = H;
If HH[1,2] < LL[1,2] Then
{
For j = 10 DownTo 2
{
HH[j,1] = HH[j-1,1];
HH[j,2] = HH[j-1,2];
}
}
If HH[1,2] < LL[1,2] or HH[1,1] < H Then
{
HH[1,1] = H;
HH[1,2] = Index;
sBar = Index - LL[1,2];
eBar = 0;
If TL_GetBeginDate(TL1) == sDate[sBar] and TL_GetBeginTime(TL1) == sTime[sBar] Then
{
TL_Delete(TL1);
Text_Delete(Text1);
}
if LL[1,1] > 0 Then
{
TL1 = TL_New(sDate[sBar],sTime[sBar],LL[1,1],sDate[eBar],sTime[eBar],HH[1,1]);
Text1 = Text_New(sDate[eBar],sTime[eBar],HH[1,1],NewLine+NumToStr(HH[1,1],2));
Text_SetStyle(Text1, 2, 1);
}
Else
{
Text_Delete(text1);
Text1 = Text_New(sDate[eBar],sTime[eBar],HH[1,1],NewLine+NumToStr(HH[1,1],2));
Text_SetStyle(Text1, 2, 1);
}
Text_SetStyle(Text1, 2, 1);
}
}
If process == -1 Then
{
T = -1;
lastLoVal = L;
If LL[1,2] < HH[1,2] Then
{
For j = 10 DownTo 2
{
LL[j,1] = LL[j-1,1];
LL[j,2] = LL[j-1,2];
}
}
If LL[1,2] < HH[1,2] or LL[1,1] > L Then
{
LL[1,1] = L;
LL[1,2] = Index;
sBar = Index - HH[1,2];
eBar = 0;
If TL_GetBeginDate(TL1) == sDate[sBar] and TL_GetBeginTime(TL1) == sTime[sBar] Then
{
TL_Delete(TL1);
Text_Delete(Text1);
}
if HH[1,1] > 0 Then
{
TL1 = TL_New(sDate[sBar],sTime[sBar],HH[1,1],sDate[eBar],sTime[eBar],LL[1,1]);
Text1 = Text_New(sDate[eBar],sTime[eBar],LL[1,1],NumToStr(LL[1,1],2));
Text_SetStyle(Text1, 2, 0);
}
Else
{
Text_Delete(text1);
Text1 = Text_New(sDate[eBar],sTime[eBar],LL[1,1],NumToStr(LL[1,1],2));
Text_SetStyle(Text1, 2, 0);
}
}
}
if T == 1 and CrossUp(C,HH[2,1]) Then
Buy();
if T == -1 and CrossDown(C,LL[2,1]) Then
Sell();
2022-07-18
2279
글번호 160812
시스템