예스스탁
예스스탁 답변
2025-05-09 09:18:10
안녕하세요
예스스탁입니다.
Input : short(12), long(26), signal(9),굵기(5);
input : 텍스트출력(0),선굵기(5),상승세로선색(cyan),하락세로선색(green),세로선굵기(4);
Var : MACDV(0) , MACDS(0),T(0),vtl(0);
var : HIV(0),HID(0),HIT(0),HIV1(0),HID1(0),HIT1(0);
var : HPV(0),HPD(0),HPT(0),HPV1(0),HPD1(0),HPT1(0);
var : LIV(0),LID(0),LIT(0),LIV1(0),LID1(0),LIT1(0);
var : LPV(0),LPD(0),LPT(0),LPV1(0),LPD1(0),LPT1(0);
var : TL1(0),TL2(0);
MACDV = MACD(short, long);
MACDS = ema(MACDV,signal);
if crossup(MACDV,MACDS) Then
{
T = 1;
HIV = MACDV;
HID = sdate;
HIT = stime;
HIV1 = HIV[1];
HID1 = HID[1];
HIT1 = HIT[1];
HPV = L;
HPD = sdate;
HPT = stime;
HPV1 = HPV[1];
HPD1 = HPD[1];
HPT1 = HPT[1];
Condition1 = false;
}
if CrossDown(MACDV,MACDS) Then
{
T = -1;
LIV = MACDV;
LID = sdate;
LIT = stime;
LIV1 = LIV[1];
LID1 = LID[1];
LIT1 = LIT[1];
LPV = L;
LPD = sdate;
LPT = stime;
LPV1 = LPV[1];
LPD1 = LPD[1];
LPT1 = LPT[1];
Condition2 = false;
}
if T == 1 Then
{
if MACDV > HIV Then
{
HIV = MACDV;
HID = sdate;
HIT = stime;
}
if H > HPV Then
{
HPV = H;
HPD = sdate;
HPT = stime;
}
if Condition1 == false and HPV1 > 0 and HPV > HPV1 and HIV < HIV1 Then
{
TL1 = TL_New(HPD1,HPT1,HPV1,HPD,HPT,HPV);
TL2 = TL_New_Self(HID1,HIT1,HIV1,HID,HIT,HIV);
TL_SetColor(TL1,blue);
TL_SetColor(TL2,red);
TL_SetSize(TL1,굵기);
TL_SetSize(TL2,굵기);
Condition1 = true;
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
vtl = TL_New(sDate,sTime,0,sdate,sTime,999999999);
TL_SetColor(vtl,하락세로선색);
TL_SetSize(vtl,세로선굵기);
}
if Condition1 == true then
{
if HPV > HPV1 and HIV < HIV1 then
{
TL_SetEnd(TL1,HPD,HPT,HPV);
TL_SetEnd(TL2,HID,HIT,HIV);
TL_SetBegin(vtl,HPD,HPT,0);
TL_SetEnd(vtl,HPD,HPT,999999999);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
}
Else
{
TL_Delete(TL1);
TL_Delete(TL2);
TL_Delete(Vtl);
}
}
}
if T == -1 Then
{
if MACDV < LIV Then
{
LIV = MACDV;
LID = sdate;
LIT = stime;
}
if L < LPV Then
{
LPV = L;
LPD = sdate;
LPT = stime;
}
if Condition2 == false and LPV1 > 0 and LPV < LPV1 and LIV > LIV1 Then
{
TL1 = TL_New(LPD1,LPT1,LPV1,LPD,LPT,LPV);
TL2 = TL_New_Self(LID1,LIT1,LIV1,LID,LIT,LIV);
TL_SetColor(TL1,red);
TL_SetColor(TL2,blue);
TL_SetSize(TL1,굵기);
TL_SetSize(TL2,굵기);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
vtl = TL_New(sDate,sTime,0,sdate,sTime,999999999);
TL_SetColor(vtl,상승세로선색);
TL_SetSize(vtl,세로선굵기);
Condition2 = true;
}
if Condition2 == true then
{
if LPV < LPV1 and LIV > LIV1 then
{
TL_SetEnd(TL1,LPD,LPT,LPV);
TL_SetEnd(TL2,LID,LIT,LIV);
TL_SetBegin(vtl,LPD,LPT,0);
TL_SetEnd(vtl,LPD,LPT,999999999);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
}
Else
{
TL_Delete(TL1);
TL_Delete(TL2);
TL_Delete(Vtl);
}
}
}
plot1(MACDV);
plot2(MACDS);
즐거운 하루되세요
> 유로파54 님이 쓴 글입니다.
> 제목 : 문의 드립니다!
> 안녕하세요!
아래 수식은 며칠전 92556번 질문에 대해 주신 답변수식입니다
이 수식을 적용해보니 상승세로선은 연장선까지도 잘 발생이되나 하락세로선이 연장선이 발생되지않고 있습니다
수고스러우시겠지만 한번더 검토 부탁드립니다
감사합니다
---------------------------------------------------------------------------------
Input : short(12), long(26), signal(9),굵기(5);
input : 텍스트출력(0),선굵기(5),상승세로선색(cyan),하락세로선색(green),세로선굵기(4);
Var : MACDV(0) , MACDS(0),T(0),vtl(0);
var : HIV(0),HID(0),HIT(0),HIV1(0),HID1(0),HIT1(0);
var : HPV(0),HPD(0),HPT(0),HPV1(0),HPD1(0),HPT1(0);
var : LIV(0),LID(0),LIT(0),LIV1(0),LID1(0),LIT1(0);
var : LPV(0),LPD(0),LPT(0),LPV1(0),LPD1(0),LPT1(0);
var : TL1(0),TL2(0);
MACDV = MACD(short, long);
MACDS = ema(MACDV,signal);
if crossup(MACDV,MACDS) Then
{
T = 1;
HIV = MACDV;
HID = sdate;
HIT = stime;
HIV1 = HIV[1];
HID1 = HID[1];
HIT1 = HIT[1];
HPV = L;
HPD = sdate;
HPT = stime;
HPV1 = HPV[1];
HPD1 = HPD[1];
HPT1 = HPT[1];
Condition1 = false;
}
if CrossDown(MACDV,MACDS) Then
{
T = -1;
LIV = MACDV;
LID = sdate;
LIT = stime;
LIV1 = LIV[1];
LID1 = LID[1];
LIT1 = LIT[1];
LPV = L;
LPD = sdate;
LPT = stime;
LPV1 = LPV[1];
LPD1 = LPD[1];
LPT1 = LPT[1];
Condition2 = false;
}
if T == 1 Then
{
if MACDV > HIV Then
{
HIV = MACDV;
HID = sdate;
HIT = stime;
}
if H > HPV Then
{
HPV = H;
HPD = sdate;
HPT = stime;
}
if Condition1 == false and HPV1 > 0 and HPV > HPV1 and HIV < HIV1 Then
{
TL1 = TL_New(HPD1,HPT1,HPV1,HPD,HPT,HPV);
TL2 = TL_New_Self(HID1,HIT1,HIV1,HID,HIT,HIV);
TL_SetColor(TL1,blue);
TL_SetColor(TL2,red);
TL_SetSize(TL1,굵기);
TL_SetSize(TL2,굵기);
Condition1 = true;
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
vtl = TL_New(sDate,sTime,0,sdate,sTime,999999999);
TL_SetColor(vtl,하락세로선색);
TL_SetSize(vtl,세로선굵기);
}
if Condition1 == true then
{
if HPV > HPV1 and HIV < HIV1 then
{
TL_SetEnd(TL1,HPD,HPT,HPV);
TL_SetEnd(TL2,HID,HIT,HIV);
TL_SetBegin(vtl,LPD,LPT,0);
TL_SetEnd(vtl,LPD,LPT,999999999);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
}
Else
{
TL_Delete(TL1);
TL_Delete(TL2);
TL_Delete(Vtl);
}
}
}
if T == -1 Then
{
if MACDV < LIV Then
{
LIV = MACDV;
LID = sdate;
LIT = stime;
}
if L < LPV Then
{
LPV = L;
LPD = sdate;
LPT = stime;
}
if Condition2 == false and LPV1 > 0 and LPV < LPV1 and LIV > LIV1 Then
{
TL1 = TL_New(LPD1,LPT1,LPV1,LPD,LPT,LPV);
TL2 = TL_New_Self(LID1,LIT1,LIV1,LID,LIT,LIV);
TL_SetColor(TL1,red);
TL_SetColor(TL2,blue);
TL_SetSize(TL1,굵기);
TL_SetSize(TL2,굵기);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
vtl = TL_New(sDate,sTime,0,sdate,sTime,999999999);
TL_SetColor(vtl,상승세로선색);
TL_SetSize(vtl,세로선굵기);
Condition2 = true;
}
if Condition2 == true then
{
if LPV < LPV1 and LIV > LIV1 then
{
TL_SetEnd(TL1,LPD,LPT,LPV);
TL_SetEnd(TL2,LID,LIT,LIV);
TL_SetBegin(vtl,LPD,LPT,0);
TL_SetEnd(vtl,LPD,LPT,999999999);
PlaySound("C:₩예스트레이더(X64)₩data₩Sound₩.wav");
}
Else
{
TL_Delete(TL1);
TL_Delete(TL2);
TL_Delete(Vtl);
}
}
}
plot1(MACDV);
plot2(MACDS);