답변완료
수식문의
늘 감사합니다.
수식은 잘 쓰고 있습니다.
아래의 수식을 data7의 잔량으로
data7의 차트에 표시 할수 있나요
-------
input : 기준잔량(2500);
var : v1(0,Data1),T(0,Data1),S(0,Data1);
v1 = data1(Bids-Asks);
if Bdate != Bdate[1] Then
T = 0;
if T <= 0 and V1 >= 기준잔량 Then
{
T = 1;
S = C;
}
if T >= 0 and V1 <= -기준잔량 Then
{
T = -1;
S = C;
}
if T != 0 Then
{
Plot1(S,"잔량차",IFf(T==1,Red,Blue));
}
Else
NoPlot(1);
감사합니다.
2022-11-30
764
글번호 164272
지표
답변완료
시스템식 도움부탁드립니다
아래지표를 활용하여
타주기분(15) ▲ 중 일때 현주기 ▲ 발생시 매수
타주기분(15) ▼ 중 일때 현주기 ▼ 발생시 매도
매수 청산 = 현주기 longstop 선을 종가상 아래일때
매도 청산 = 현주기 shortstop 선을 종가상 위 일때
매수손절= 신호발생시 longstop 선 값 하회시 손절
매도손절= 신호발생시 shortstop 선 값 상회시 손절
매수익절 = 신호발생시 (현재가 - longstop ) * 2 도달시
매도익절 = 신호발생시 (shortstop - 현재가 )* 2 도달시
을 시스템 식으로 부탁드립니다
수고하세요
===========
input : length(2),mult(2),useClose(true),크기(25));
var : ATrv(0),longStop(0),longStopprev(0),shortStop(0),shortStopPrev(0);
var : hsc(0),dir(1),longcolor(Orange),shortcolor(lightgreen),tx(0);
var : truehighv(0),TrueLowv(0),TrueRangev(0),hsatr(0) ;
var : xClose(0),xOpen(0),xHigh(0),xLow(0);
if index == 0 then
{
xOpen = open;
xClose = (O+H+L+C)/4;
xHigh = MaxList( high, xOpen, xClose);
xLow = MinList( low, xOpen,xClose);
}
else
{
xClose = (O+H+L+C)/4;
xOpen = (xOpen [1] + xClose [1])/2 ;
xHigh = MaxList(High, xOpen, xClose) ;
xLow = MinList(Low, xOpen, xClose) ;
}
////////
If xClose[1] > xHigh then
TrueHighv = xClose[1];
else
TrueHighv = xHigh;
If xClose[1] < xLow then
TrueLowv = xClose[1];
else
TrueLowv = xLow;
TrueRangev = TrueHighv - TrueLowv;
hsatr = ma(TrueRangev,length);
hsc = xclose ;
//////////
atrv = mult * hsatr;
longStop = IFf(useClose , highest(hsc, length) , highest(xHigh,length)) - atrv;
longStopPrev = longStop[1];
longStop = iff(hsc[1] > longStopPrev , max(longStop, longStopPrev) , longStop);
shortStop = IFf(useClose , lowest(hsc, length) , lowest(xLow,length)) + atrv;
shortStopPrev = shortStop[1];
shortStop = iff(hsc[1] < shortStopPrev , min(shortStop, shortStopPrev) , shortStop);
dir = iff(hsc > shortStopPrev , 1 ,iff( hsc < longStopPrev , -1 , dir));
IF dir == 1 Then
{
plot1(longStop,"Long Stop",longColor);
NoPlot(2);
}
Else
{
NoPlot(1);
plot2(shortStop,"Short Stop",shortColor);
}
////////
/////////////
if dir == 1 and dir[1] == -1 Then
{
tx = Text_New(sDate,sTime,longStop,"▲");
Text_SetStyle(tx,2,0);
Text_SetSize(tx, 크기);
Text_SetColor(tx,red);
}
if dir == -1 and dir[1] == 1 Then
{
tx = Text_New(sDate,sTime,shortStop,"▼");
Text_SetStyle(tx,2,1);
Text_SetSize(tx, 크기);
Text_SetColor(tx,blue);
}
2022-11-30
753
글번호 164269
시스템