답변완료
문의드립니다.
아래 식에서 볼린져 밴드 20. 2를 추가해서 매수 경우 볼린져 하단선을 닿거나 돌파 한 후에 TRIX 0선 아래이고 골든 크로스 발생 할 때 매수 (피라미딩 방식)청산은 제가 직접 할 것입니다.매도 경우 볼린져 상단선을 닿거나 돌파 한 후에 TRIX 0선 위이고 데드 크로스 발생 할 때 매도 (피라미딩 방식)청산은 제가 직접 할 것입니다.부탁드립니다.Input : Period(5), sigPeriod(3);var : TRIXv(0),TRIXs(0);TRIXv = TRIX(Period);TRIXs = ema(TRIXv,sigPeriod);if CrossUp(TRIXv,TRIXs) and TRIXv < 0 Then Buy("B",OnClose,def);Input : Period(5), sigPeriod(3);var : TRIXv(0),TRIXs(0);TRIXv = TRIX(Period);TRIXs = ema(TRIXv,sigPeriod);if CrossDown(TRIXv,TRIXs) and TRIXv > 0 Then Sell("S",OnClose,def)
2025-12-23
117
글번호 229291
시스템
답변완료
추세선 전저
박스 하단 부분을 가로선으로 표시. (전저 -0.5 에 가로선)For j = 0 To 19 이 수식은 어떤 용도이며, 꼭 필요한가요? 감사합니다.input : Period(10);Var:j(0),T(0),TL(0),box1(0),box2(0);Var: date11(0),date12(0),time11(0),time12(0), date21(0),date22(0),time21(0),time22(0); Array: HiVal[20](0),LoVal[20](0),HiBar[20](0),LoBar[20](0);Plot1(value12,"value12",IFf(t==1,Red,Blue));For j = 0 To 19{ HiBar[j] = HiBar[j] + 1; LoBar[j] = LoBar[j] + 1;}if crossup(H,highest(H,Period)[1]) and (T == 0 or (T==-1 and H >= Loval[0]+0.8)) Then T = 1;if CrossDown(L,Lowest(L,Period)[1]) and (T == 0 or (T==1 and L <= Hival[0]-0.8)) Then T = -1;If T == -1 Then{ If T[1] != -1 Then { For j = 18 DownTo 0 { LoVal[j+1] = LoVal[j]; LoBar[j+1] = LoBar[j]; } LoVal[0] = L; LoBar[0] = 0; date11 = date[HiBar[0]]; time11 = stime[HiBar[0]]; Value11 = HiVal[0]; date12 = date[LoBar[0]]; time12 = stime[LoBar[0]]; Value12 = LoVal[0]; box1 = Box_New(sdate,stime,LoVal[0]-0.25,NextBarSdate,NextBarStime,LoVal[0]-0.50); Box_SetColor(box1,Yellow); Box_SetFill(box1,true,90); box2 = box1[1]; Box_SetEnd(box2,Sdate,Stime,LoVal[1]-0.50); } If LoVal[0] > L Then { LoVal[0] = L; LoBar[0] = 0; date12 = date[LoBar[0]]; time12 = stime[LoBar[0]]; Value12 = LoVal[0]; Box_SetBegin(box1,sDate,sTime,LoVal[0]-0.25); Box_SetEnd(box2,Sdate,Stime,LoVal[1]-0.50); } } Box_SetEnd(box1,NextBarSdate,NextBarStime,LoVal[0]-0.50); If T == 1 Then{ If T[1] != 1 Then { For j = 18 DownTo 0 { HiVal[j+1] = HiVal[j]; HiBar[j+1] = HiBar[j]; } HiVal[0] = H; HiBar[0] = 0; date11 = date[LoBar[0]]; time11 = stime[LoBar[0]]; Value11 = LoVal[0]; date12 = date[HiBar[0]]; time12 = stime[HiBar[0]]; Value12 = HiVal[0]; } If HiVal[0] < H Then { HiVal[0] = H; HiBar[0] = 0; date12 = date[HiBar[0]]; time12 = stime[HiBar[0]]; Value12 = HiVal[0]; } }
2025-12-23
220
글번호 229278
지표
답변완료
지표수식 문의
안녕하세요... 차트에 1번과 2번 , 2개의 라인 긋는 지표 수식 부탁드려요a = wavg(2 * wavg(src, len / 2) - wavg(src, len), floor(sqrt(len))); 기준 = a(1) >a ; b = CountSince(기준, a(1)<a) ; ab=valuewhen(1, b==1 && b(1)==0, h); <1번라인> valuewhen(1, b==1 && b(1)==0, h) <2번라인> valuewhen(1, (a+ab)/2, L) (지표조건 : src 15, len 종가)감사합니다.
2025-12-23
128
글번호 229276
지표
답변완료
보조지표 및 검색식 요청 드립니다
트레이딩뷰에 있는 지표 인데요.. 예스트레이더로 변환이 가능 할까요?가능 하다면 지표(아마 예스트레이더에선 강조가 될듯합니다)와 검색식을 부탁 드리고자 합니다 검색식은 첨부 그림처럼 buy신호가 뜰때 입니다source = closehilow = ((high - low)*100)openclose = ((close - open)*100)vol = (volume / hilow)spreadvol = (openclose * vol)VPT = spreadvol + cum(spreadvol)window_len = 28v_len = 14price_spread = stdev(high-low, window_len)v = spreadvol + cum(spreadvol)smooth = sma(v, v_len)v_spread = stdev(v - smooth, window_len)shadow = (v - smooth) / v_spread * price_spreadout = shadow > 0 ? high + shadow : low + shadow//plot(out, style=line,linewidth=3, color=color)len=input(10)vpt=ema(out,len)//lineColor = vpt > vpt[1] ? color.green : color.red//plot(vpt, linewidth=3, color=lineColor)//x=crossover(vpt , vpt[1]) and vpt > vpt[1]//z=crossunder(vpt , vpt[1]) and vpt <vpt[1]//plotshape(crossover(vpt , vpt[1]) and vpt > vpt[1], "up arrow", shape.triangleup, location.belowbar, color.green,size=size.tiny)//plotshape(crossunder(vpt , vpt[1]) and vpt <vpt[1] , "down arrow", shape.triangledown, location.abovebar, color.red,size=size.tiny)//// INPUTS //st_mult = input(1, title = 'SuperTrend Multiplier', minval = 0, maxval = 100, step = 0.01)st_period = input(100, title = 'SuperTrend Period', minval = 1)// CALCULATIONS //up_lev = vpt - (st_mult * atr(st_period))dn_lev = vpt + (st_mult * atr(st_period))up_trend = 0.0up_trend := close[1] > up_trend[1] ? max(up_lev, up_trend[1]) : up_levdown_trend = 0.0down_trend := close[1] < down_trend[1] ? min(dn_lev, down_trend[1]) : dn_lev// Calculate trend vartrend = 0trend := close > down_trend[1] ? 1: close < up_trend[1] ? -1 : nz(trend[1], 1)// Calculate SuperTrend Linest_line = trend ==1 ? up_trend : down_trend// Plottingplot(st_line[1], color = trend == 1 ? color.green : color.red , style = plot.style_cross, linewidth = 2, title = "SuperTrend")buy=crossover( close, st_line)sell=crossunder(close, st_line)//plotshape(crossover( close, st_line), location = location.belowbar, color = color.green,size=size.tiny)//plotshape(crossunder(close, st_line), location = location.abovebar, color = color.red,size=size.tiny)plotshape(buy,title="Buy", color=color.blue, style=shape.arrowup,location=location.belowbar, text="Buy")plotshape(sell,title="Sell", color=color.black, style=shape.arrowdown,text="Sell")/////// Alerts /////alertcondition(buy,title="buy")alertcondition(sell,title="sell")
2025-12-22
247
글번호 229260
지표