답변완료
수식추가
Inputs : Period(170), Sence(1.3), CC_DN(Yellow);
Vars:
VLineUp(0),
VLineDn(0),
HHighest(0),
LLowest(0),
JustChanged(FALSE),
VLine(0), DBN(0);
Array:
Highs[35](0),
Lows[35](0),
RRange[35](0),
UpWave[1](FALSE),
DnWave[1](FALSE);
If STime == 180000 Then
DBN = 0;
DBN = DBN + 1;
Var1 = Period;
Var2 = Var1 - 1;
Var3 = Var1 - 2;
Var5 = Sence;
Var6 = H-L;
JustChanged = FALSE;
if CurrentBar <= Var2 then begin
Highs[CurrentBar] = Close;
Lows[CurrentBar] = Close;
RRange[CurrentBar] = (H-L) /2;
end;
if CurrentBar == Var1 then begin
if Highs[Var2] >= Highs[Var3] then begin
UpWave[1] = TRUE;
HHighest = Highs[Var2];
VLineUp = HHighest - (Var5 * MA(Var6,Var2));
#Plot1(VLineUp,"VLineUp");
end;
if Highs[Var2] < Highs[Var3] then begin
DnWave[1] = TRUE;
LLowest = Lows[Var2];
VLineDn = LLowest + (Var5 * MA(Var6,Var2));
#Plot2(VLineDn,"VLineDn");
end;
end;
if CurrentBar > Var1 then begin
if DnWave[1] and Close > VLineDn then begin
DnWave[1] = FALSE;
UpWave[1] = TRUE;
JustChanged = TRUE;
HHighest = Close;
LLowest = 0;
end;
if UpWave[1] and Close < VLineUp and JustChanged == FALSE then begin
UpWave[1] = FALSE;
DnWave[1] = TRUE;
JustChanged = TRUE;
LLowest = Close;
HHighest = 0;
end;
if JustChanged == FALSE then begin
if Close > HHighest then
HHighest = Close;
else if Close < LLowest then
LLowest = Close;
end;
VLineUp = HHighest - (Var5 * MA(Var6,Var2));
VLineDn = LLowest + (Var5 * MA(Var6,Var2));
/*if UpWave[1] then Plot1(VLineUp,"VLineUp", Red);
else if DnWave[1] then Plot1(VLineDn,"VLineUp", Blue);
*/
end;
input : P(10),short(12),long(26),sig(9);
var : mav(0),macdo(0),T(0);
mav = ma(C,P);
MACDo = MACD_OSC(short,long,sig);
if T <= 0 and upwave[1] and c > mav and macdo > 0 Then
{
t =1;
Buy();
}
if T >= 0 and dnwave[1] and c < mav and macdo < 0 Then
{
T = -1;
Sell();
}
안녕하세요
위식에서 추가부탁드립니다
DATE 2 30분봉 추가
INPUT 30분봉
매수 기존식에서 30분봉 양봉일때 매수
매도 기존식 + 30분봉 음봉일때 매도
2024-03-08
735
글번호 177298
시스템
답변완료
좋은 주말 되십시요^^
좋은 주말 되십시요**
<요청 사항>
https://www.youtube.com/watch?v=162SlkuTcs0
https://www.youtube.com/watch?v=JSqwubnXmwo
https://www.youtube.com/watch?v=_fRtlnU8FQw
https://www.youtube.com/watch?v=lCIw8uaHAJE
https://www.youtube.com/watch?v=7CBoAzfK0jg
안녕하세요
예스스탁입니다.
input : p1(10),P(10),p2(10),k(2);
var : a(false),b(0);
a=c<highest(c,p1)-ATR(p)*k or c<lowest(c,p2)[1];
if a == true Then
b = h;
if b > 0 Then
Plot1(b);
즐거운 하루되세요
> wasong 님이 쓴 글입니다.
input : per(8);
input : smthit(false);
input : type(0); #1: SMA, 2: EMA, 3: WMA, 4: RMA
input : smthper(5);
input : colorbars(false);
input : showsignals(false);
var : mav(0),atrv(0),out(0),variant(0),alpha(0),rma(0),colorout(0),tx(0);
mav = ma(close - close[per], per);
atrv = atr(per);
out = mav/atrv * 50 + 50;
if type == 1 Then
variant = ma(out, smthper) ;
else if type == 2 Then
variant = ema(out, smthper);
else if type == 3 Then
variant = wma(out, smthper) ;
else if type == 4 Then
{
alpha = 1/smthper;
rma = IFf(IsNaN(rma[1]) == true, ma(out, smthper) , alpha * out + (1 - alpha) *IFf(IsNan(rma[1])==true,0,rma[1]));
variant = rma;
}
out = iff(smthit ,variant , out);
colorout = iff(out > 50 , green , red);
plot1(out,"out",colorout);
plot2(50,"50",gray);
if CrossUp(out,50) Then
{
tx = Text_New(sDate,sTime,L,"▲");
Text_SetColor(tx,Green);
Text_SetStyle(tx,2,0);
}
if CrossDown(out,50) Then
{
tx = Text_New(sDate,sTime,H,"▼");
Text_SetColor(tx,Red);
Text_SetStyle(tx,2,1);
}
즐거운 하루되세요
안녕하세요
예스스탁입니다.
input : Period(10),multiple(2);
var : base(0),upper_band(0),downtrend(0);
Base=(H+L)/2;
upper_band = base+atr(period)*multiple;
if lowest(upper_band,period)[1] > upper_band Then
downtrend = upper_band;
Plot1(downtrend);
즐거운 하루되세요
var : A(0),B(0),EU(0),ED(0),S1(0),S2(0),S3(0),SU(0),HU(0);
A=EnvelopeUp(20,6);
B=EnvelopeDown(20,6);
EU=((A+B)/2)+0.5*ATR(5);
ED=((A+B)/2)-0.5*ATR(5);
S1=Ema(EU,5);
S2=Ema(ED,5);
S3=(S1+S2)/2;
SU=iff(C>S3,S1,0);
if SU > SU[1] Then
HU = SU;
if HU > 0 Then
Plot1(HU);
즐거운 하루되세요
input : A_Period(10),Period(20),ratio(1),기간(5);
var : 가격(0),A(0),upt(0),dnt(0),cc(0),turn(0),라인(0),value(0);
가격 = (H+L)/2;
A=atr(A_period);
upT=Ema(가격+A*ratio,기간);
dnT=Ema(가격-A*ratio,기간);
CC=CCI(period);
turn= iff(CC>=0 && dnT>dnT[1],1, iff(CC<0 && upT<upT[1],-1,0));
라인=iff(turn==-1,upT,dnT);
if turn==1 or turn==-1 Then
value = 라인;
Plot1(value);
즐거운 하루되세요
안녕하세요
예스스탁입니다.
1
input : Period(10),sig(10);
var : sumTR(0),TH(0),TL(0),cnt(0),A(0),ATRV(0);
var : ii(0),sumATR(0),ATRS(0);
sumATR = 0;
for ii = 0 to sig-1
{
sumTR = 0;
for cnt = ii to ii+Period-1
{
TH = max(DayClose(cnt),DayOpen(cnt));
TL = min(DayClose(cnt),DayOpen(cnt));
sumTR = sumTR + (TH-TL);
}
A = sumTR/Period;
sumATR = sumATR+A;
if ii == 0 Then
ATRV = A;
}
ATRS = sumATR/Sig;
plot1(ATRV);
plot2(ATRS);
안녕하세요
예스스탁입니다.
input : coeff(1);
input : AP(14);
input : novolumedata(1);#1:true, 0:False
var : atrv(0),src(0),upt(0),downt(0),AlphaTrend(0);
var : buySignalk(False),sellSignalk(False);
ATRv = ma(TrueRange, AP);
src = close;
upT = low - ATRv * coeff;
downT = high + ATRv * coeff;
Condition1 = False;
if novolumedata == 1 and rsi(AP) >= 50 Then
Condition1 = true;
if novolumedata == 0 and MFI(AP) >= 50 Then
Condition1 = true;
AlphaTrend = iff(Condition1 , IFf(upT < iff(isnan(AlphaTrend[1])==true,0,AlphaTrend[1]), iff(isnan(AlphaTrend[1])==true,0,AlphaTrend[1]) , upT),IFf(downT > iff(isnan(AlphaTrend[1])==true,0,AlphaTrend[1]) , iff(isnan(AlphaTrend[1])==true,0,AlphaTrend[1]) , downT));
plot1(AlphaTrend,"k1",Blue);
plot2(AlphaTrend[2],"k2",Red);
즐거운 하루되세요
안녕하세요
예스스탁입니다.
1
input : Length(5),xPrice(close);
var : xe1(0),xe2(0),xe3(0),xe4(0),xe5(0),xe6(0);
var : b(0),c1(0),c2(0),c3(0),c4(0),nT3Average(0);
xe1 = ema(xPrice, Length);
xe2 = ema(xe1, Length);
xe3 = ema(xe2, Length);
xe4 = ema(xe3, Length);
xe5 = ema(xe4, Length);
xe6 = ema(xe5, Length);
b = 0.7;
c1 = -b*b*b;
c2 = 3*b*b+3*b*b*b;
c3 = -6*b*b-3*b-3*b*b*b;
c4 = 1+3*b+b*b*b+3*b*b;
nT3Average = c1 * xe6 + c2 * xe5 + c3 * xe4 + c4 * xe3;
plot1(nT3Average,"T3",lime);
안녕하세요
예스스탁입니다.
input : Period(20),multiple(2);
var : base(0),upper_band(0),downtrend(0),lower_band(0),uptrend(0);
var : Emav(0);
base=(H+L)/2;
upper_band=base + atr(period)*multiple;
lower_band=base - atr(period)*multiple;
if lowest(upper_band,period)[1]>upper_band Then
downtrend=upper_band;
if highest(lower_band,period)[1]<lower_band Then
uptrend=lower_band;
Emav = Ema(C,120);
var1 = iff(Emav<c,uptrend,downtrend);
Plot1(downtrend);
Plot2(uptrend);
Plot3(var1);
즐거운 하루되세요
아래 수식에서 박스로 수식 요청 드립니다.
즉 수직선 줄을 우측 으로 30봉 까지 박스 형태로 그리고 싶습니다.
(색상 : 회색 채우기) 선두께 : 2
var26 = ma(c,5) ;
var40 = ma(c,10) ;
if CrossUp(Var26,VAR40) Then
{
PlotPaintBar((C+L)/2-PriceScale*20,(C+L)/2-PriceScale*30 ,"강조",Rgb(255,0,0),Def,5);
}
* 좋은 주말 되시고 건강 하세요^^
2024-08-07
1072
글번호 177291
강조