커뮤니티
문의드립니다.
2018-11-19 17:00:40
227
글번호 123773
도움주시는 덕분에 도전하고 있습니다. 매번 감사합니다.
1. 지표 변환부탁드립니다.
// SvePivots
// Sylvain Vervoort
// TASC Dec 2018
inputs:
int R3Color( RGB(250,48,8) ),
int R2Color( RGB(250,100,103) ),
int R1Color( RGB(252,180,148) ),
int PivotColor( RGB(240,209,50)
),
int S1Color( RGB(192,221,250) ),
int S2Color( RGB(113,181,250) ),
int S3Color( RGB(35,141,247) ),
int YestHighColor(
RGB(18,252,65) ),
int YestLowColor(
RGB(252,18,61) ) ;
variables:
intrabarpersist int BT( 0 ),
int CurrSess( 0 ),
bool CalcTrigger( false ),
double S1( 0 ),
double S2( 0 ),
double S3( 0 ),
double R1( 0 ),
double R2( 0 ),
double R3( 0 ),
double SM1( 0 ),
double SM2( 0 ),
double SM3( 0 ),
double RM1( 0 ),
double RM2( 0 ),
double RM3( 0 ),
double PP( 0 ),
double TodaysHigh( 0 ),
double YestHigh( 0 ),
double TodaysLow( 0 ),
double YestLow( 0 ),
double TodaysClose( 0 ),
double YestClose( 0 ),
int Counter( 0 );
CurrSess = CurrentSession( 0 );
CalcTrigger = CurrSess <> CurrSess[1];
if CalcTrigger then
begin
if CurrentBar > 1 then
Counter = Counter + 1;
YestHigh = TodaysHigh;
YestLow = TodaysLow;
YestClose = Close[1];
TodaysHigh = High;
TodaysLow = Low;
PP = ( YestHigh + YestLow + YestClose ) / 3;
R1 = PP * 2 - YestLow;
R2 = PP + YestHigh - YestLow;
R3 = PP * 2 + ( YestHigh - YestLow * 2 ) ;
S1 = PP * 2 - YestHigh;
S2 = PP - YestHigh + YestLow;
S3 = PP * 2 - ( YestHigh * 2 - YestLow ) ;
RM1 = ( R1 - PP ) / 2 + PP ;
SM1 = ( PP - S1 ) / 2 + S1 ;
RM2 = ( R2 - R1 ) / 2 + R1 ;
SM2 = ( S1 - S2 ) / 2 + S2 ;
RM3 = ( R3 - R2 ) / 2 + R2 ;
SM3 = ( S2 - S3 ) / 2 + S3 ;
if BT <> 2 then
begin
SetPlotColor[1]( 1, Transparent );
SetPlotColor[1]( 2, Transparent );
SetPlotColor[1]( 3, Transparent );
SetPlotColor[1]( 4, Transparent );
SetPlotColor[1]( 5, Transparent );
SetPlotColor[1]( 6, Transparent );
SetPlotColor[1]( 7, Transparent );
SetPlotColor[1]( 8, Transparent );
SetPlotColor[1]( 9, Transparent );
SetPlotColor[1]( 10, Transparent );
SetPlotColor[1]( 11, Transparent );
SetPlotColor[1]( 12, Transparent );
SetPlotColor[1]( 13, Transparent );
SetPlotColor[1]( 14, Transparent );
SetPlotColor[1]( 15, Transparent );
end;
end
else
begin
if High > TodaysHigh then
TodaysHigh = High;
if Low < TodaysLow then
TodaysLow = Low;
end;
if Counter >= 2 then
begin
Plot1( R3, "R3", R3Color );
Plot2( R2, "R2", R2Color );
Plot3( R1, "R1", R1Color );
Plot4( PP, "PP", PivotColor );
Plot5( S1, "S1", S1Color );
Plot6( S2, "S2", S2Color );
Plot7( S3, "S3", S3Color );
Plot8( RM3, "RM3", R3Color );
Plot9( RM2, "RM2", R2Color );
Plot10( RM1, "RM1", R1Color );
Plot11( SM1, "SM1", S1Color );
Plot12( SM2, "SM2", S2Color );
Plot13( SM3, "SM3", S3Color );
Plot14( YestHigh, "YestHigh",
YestHighColor ) ;
Plot15( YestLow, "YestLow",
YestLowColor) ;
end;
2. 기타
1 지표 해선용으로 부탁드립니다.
High값이나 Low값이나 close값있으면 starttime부터 endtime까지의 H값이나 L값으로 수정부탁드립니다. 매번 귀찮은 작업 요청드려 죄송합니다.
답변 1
예스스탁 예스스탁 답변
2018-11-23 09:50:23
안녕하세요? 예스스탁입니다.
수식담당자 휴가중이라서 대신 답변드리고 있는데, 올려주신 랭귀지를 알지 못해서 답변을 드리지 못합니다. 죄송합니다만, 다음주 수요일 이후에 다시 글 올려 주시길 부탁드립니다.
감사합니다.
> 잡다백수 님이 쓴 글입니다.
> 제목 : 문의드립니다.
> 도움주시는 덕분에 도전하고 있습니다. 매번 감사합니다.
1. 지표 변환부탁드립니다.
// SvePivots
// Sylvain Vervoort
// TASC Dec 2018
inputs:
int R3Color( RGB(250,48,8) ),
int R2Color( RGB(250,100,103) ),
int R1Color( RGB(252,180,148) ),
int PivotColor( RGB(240,209,50)
),
int S1Color( RGB(192,221,250) ),
int S2Color( RGB(113,181,250) ),
int S3Color( RGB(35,141,247) ),
int YestHighColor(
RGB(18,252,65) ),
int YestLowColor(
RGB(252,18,61) ) ;
variables:
intrabarpersist int BT( 0 ),
int CurrSess( 0 ),
bool CalcTrigger( false ),
double S1( 0 ),
double S2( 0 ),
double S3( 0 ),
double R1( 0 ),
double R2( 0 ),
double R3( 0 ),
double SM1( 0 ),
double SM2( 0 ),
double SM3( 0 ),
double RM1( 0 ),
double RM2( 0 ),
double RM3( 0 ),
double PP( 0 ),
double TodaysHigh( 0 ),
double YestHigh( 0 ),
double TodaysLow( 0 ),
double YestLow( 0 ),
double TodaysClose( 0 ),
double YestClose( 0 ),
int Counter( 0 );
CurrSess = CurrentSession( 0 );
CalcTrigger = CurrSess <> CurrSess[1];
if CalcTrigger then
begin
if CurrentBar > 1 then
Counter = Counter + 1;
YestHigh = TodaysHigh;
YestLow = TodaysLow;
YestClose = Close[1];
TodaysHigh = High;
TodaysLow = Low;
PP = ( YestHigh + YestLow + YestClose ) / 3;
R1 = PP * 2 - YestLow;
R2 = PP + YestHigh - YestLow;
R3 = PP * 2 + ( YestHigh - YestLow * 2 ) ;
S1 = PP * 2 - YestHigh;
S2 = PP - YestHigh + YestLow;
S3 = PP * 2 - ( YestHigh * 2 - YestLow ) ;
RM1 = ( R1 - PP ) / 2 + PP ;
SM1 = ( PP - S1 ) / 2 + S1 ;
RM2 = ( R2 - R1 ) / 2 + R1 ;
SM2 = ( S1 - S2 ) / 2 + S2 ;
RM3 = ( R3 - R2 ) / 2 + R2 ;
SM3 = ( S2 - S3 ) / 2 + S3 ;
if BT <> 2 then
begin
SetPlotColor[1]( 1, Transparent );
SetPlotColor[1]( 2, Transparent );
SetPlotColor[1]( 3, Transparent );
SetPlotColor[1]( 4, Transparent );
SetPlotColor[1]( 5, Transparent );
SetPlotColor[1]( 6, Transparent );
SetPlotColor[1]( 7, Transparent );
SetPlotColor[1]( 8, Transparent );
SetPlotColor[1]( 9, Transparent );
SetPlotColor[1]( 10, Transparent );
SetPlotColor[1]( 11, Transparent );
SetPlotColor[1]( 12, Transparent );
SetPlotColor[1]( 13, Transparent );
SetPlotColor[1]( 14, Transparent );
SetPlotColor[1]( 15, Transparent );
end;
end
else
begin
if High > TodaysHigh then
TodaysHigh = High;
if Low < TodaysLow then
TodaysLow = Low;
end;
if Counter >= 2 then
begin
Plot1( R3, "R3", R3Color );
Plot2( R2, "R2", R2Color );
Plot3( R1, "R1", R1Color );
Plot4( PP, "PP", PivotColor );
Plot5( S1, "S1", S1Color );
Plot6( S2, "S2", S2Color );
Plot7( S3, "S3", S3Color );
Plot8( RM3, "RM3", R3Color );
Plot9( RM2, "RM2", R2Color );
Plot10( RM1, "RM1", R1Color );
Plot11( SM1, "SM1", S1Color );
Plot12( SM2, "SM2", S2Color );
Plot13( SM3, "SM3", S3Color );
Plot14( YestHigh, "YestHigh",
YestHighColor ) ;
Plot15( YestLow, "YestLow",
YestLowColor) ;
end;
2. 기타
1 지표 해선용으로 부탁드립니다.
High값이나 Low값이나 close값있으면 starttime부터 endtime까지의 H값이나 L값으로 수정부탁드립니다. 매번 귀찮은 작업 요청드려 죄송합니다.
다음글
이전글