커뮤니티

예스랭귀지 Q&A

글쓰기
답변완료

부틱드립니다

수고하십니다 트레이딩 뷰 수식입니다. 예스로적용가능하도록 부탁 드립니다. //@version=4 study("Supertrend", overlay = true, format=format.price, precision=2, resolution="") Periods = input(title="ATR Period", type=input.integer, defval=10) src = input(hl2, title="Source") Multiplier = input(title="ATR Multiplier", type=input.float, step=0.1, defval=3.0) changeATR= input(title="Change ATR Calculation Method ?", type=input.bool, defval=true) showsignals = input(title="Show Buy/Sell Signals ?", type=input.bool, defval=true) highlighting = input(title="Highlighter On/Off ?", type=input.bool, defval=true) atr2 = sma(tr, Periods) atr= changeATR ? atr(Periods) : atr2 up=src-(Multiplier*atr) up1 = nz(up[1],up) up := close[1] > up1 ? max(up,up1) : up dn=src+(Multiplier*atr) dn1 = nz(dn[1], dn) dn := close[1] < dn1 ? min(dn, dn1) : dn trend = 1 trend := nz(trend[1], trend) trend := trend == -1 and close > dn1 ? 1 : trend == 1 and close < up1 ? -1 : trend upPlot = plot(trend == 1 ? up : na, title="Up Trend", style=plot.style_linebr, linewidth=2, color=color.green) buySignal = trend == 1 and trend[1] == -1 plotshape(buySignal ? up : na, title="UpTrend Begins", location=location.absolute, style=shape.circle, size=size.tiny, color=color.green, transp=0) plotshape(buySignal and showsignals ? up : na, title="Buy", text="Buy", location=location.absolute, style=shape.labelup, size=size.tiny, color=color.green, textcolor=color.white, transp=0) dnPlot = plot(trend == 1 ? na : dn, title="Down Trend", style=plot.style_linebr, linewidth=2, color=color.red) sellSignal = trend == -1 and trend[1] == 1 plotshape(sellSignal ? dn : na, title="DownTrend Begins", location=location.absolute, style=shape.circle, size=size.tiny, color=color.red, transp=0) plotshape(sellSignal and showsignals ? dn : na, title="Sell", text="Sell", location=location.absolute, style=shape.labeldown, size=size.tiny, color=color.red, textcolor=color.white, transp=0) mPlot = plot(ohlc4, title="", style=plot.style_circles, linewidth=0) longFillColor = highlighting ? (trend == 1 ? color.green : color.white) : color.white shortFillColor = highlighting ? (trend == -1 ? color.red : color.white) : color.white fill(mPlot, upPlot, title="UpTrend Highligter", color=longFillColor) fill(mPlot, dnPlot, title="DownTrend Highligter", color=shortFillColor) alertcondition(buySignal, title="SuperTrend Buy", message="SuperTrend Buy!") alertcondition(sellSignal, title="SuperTrend Sell", message="SuperTrend Sell!") changeCond = trend != trend[1] alertcondition(changeCond, title="SuperTrend Direction Change", message="SuperTrend has changed direction!")
프로필 이미지
파생돌이
2024-09-17
674
글번호 183475
지표
답변완료

종목검색식 요청드립니다.

아래 키움수식을 만족하는 종목검색식을 만들고 싶습니다. 도움 부탁드리겠습니다. 항상 좋은 일만 가득하시길 바랍니다.^^ * 키움수식 S=BBandsup(20,3); M=ma(C,20); 조건=M>M(1) && Crossup(S, M); bs=BarsSince(조건); bs > 0 && CrossDown(S, M) && M > M(1) && C(1) < S(1) 감사합니다.
프로필 이미지
onlypsn
2024-09-17
834
글번호 183474
종목검색
답변완료

키움수식 종목검색

A=(C - lowest(C, 20))/C*100; B=(highest(C, 20)- C)/C*100; AA=MAX(A, 0); BB=MAX(B, 0); SS=ADX(11); AAA=CrossUP(c, c(13)); BBB=CrossUP(c, c(26)); CrossUP(A, B) && CrossUP(AA, BB)&& SS(1)<SS && SS(2)<SS&& CrossUP(c, c(13))OR CrossUP(BBB, AAA)
프로필 이미지
박셰프
2024-09-16
714
글번호 183473
종목검색
답변완료

나스닥 선물을...

거래하면서 청산은 setstoploss와 setstopprofittarget 만을 사용하고 있습니다. 전략실행 설정창에서 청산할 때 사용자 가격설정을 선택하고 atlimit는 신호가, atstop 은 현재가+-2 로 설정하면 setstopprofittarget은 신호가로, setstoploss는 현재가+-2호가로 주문이 실행되는 것이 맞나요? 아니면 어떻게 주문이 실행되는 것인가요? 그리고 하루에 약20회 매매시 실제 청산내역을 토대로 계산해 보면 플러스 슬리피지가 나오는 날이 대부분인데 다른 분들도 그런가요? 시장가는 전혀 사용하지 않고 있는데도요... 매우 궁금합니다. 미리 감사드립니다.
프로필 이미지
자마이카
2024-09-17
653
글번호 183472
시스템
답변완료

검색식 부탁 드려요

1. 기준선이 하락할때 종목검색식 부탁드립니다.(일봉) 2. 지난 20일 동안 전환선이 기준선을 골든크로스한 종목검색식 부탁드립니다. 3. 지난 10일 동안 10이평이 60 이평을 골든크로스한 종목검색식 부탁드려요.(단순이평) 4. 전환선이 볼린저밴드 (20,2) 중심선 돌파 종목검색식 5. 기준선이 볼린저밴드 (20,2) 중심선 돌파 종목검색식 6. 전환선이 볼린저밴드 (20,2) 중심선 위에 있는 종목검색식 7. 기준선이 볼린저밴드 (20,2) 중심선 위에 있는 종목검색식 8. 전환선이 볼린저밴드 (20,2) 상단선에 닿을때 종목검색식 9. 기준선이 볼린저밴드 (20,2) 상단선에 닿을때 종목검색식 부탁드려요.
프로필 이미지
일지매7
2024-09-18
599
글번호 183471
종목검색
답변완료

분봉에서 매수 조건 부탁드립니다.

5일안에 일봉 시가대비 종가 7%이상 상승 + 거래대금 100억 이상일 경우 매수를 표현하고 싶습니다. 감사합니다.
프로필 이미지
마녀58
2024-09-16
576
글번호 183470
지표
답변완료

청산수식 청산횟수 / 음봉비율 수정

질문1) input : exst(120000),exlock(140000),xdive(2.0); if stime>=exst and stime<exlock and c<Highd(0)-xdive Then ExitLong(); 하루 1회만 거래하는 수식에서 청산수식으로 사용한 내용입니다. 하루에 여러번 거래하는 수식에 사용하기 위해선 청산횟수를 제어하는 수식이 필요합니다. input : 청산횟수(1),exst(120000),exlock(140000),xdive(2.0); 이런식으로 제어할 수 있게 수정바랍니다. 질문2) 답변 수식 시뮬레이션 해보니 시간을 경과하지 않고 첫봉에 진입하는 경우가 많이 발생하고 있습니다.(첨부파일) 변수선언 var:t(0); 은 추가했습니다. 살펴주세요. ************************************************************************************ 안녕하세요 예스스탁입니다. input:시간1(093000); input:시간2(100000); if (sdate != sdate[1] and stime >= 시간1) or (sdate == sdate[1] and stime >= 시간1 and stime[1] < 시간1) Then { t = 1; var1 = 0; Var2 = 0; } if (sdate != sdate[1] and stime >= 시간2) or (sdate == sdate[1] and stime >= 시간2 and stime[1] < 시간2) Then { t = 2; } if t == 1 Then { var1 = var1+1; if c < o Then Var2 = Var2+1; } if t >= 2 Then { if Var2/var1*100 > 50 then sell(); } 풍성한 한가위 되시길 바랍니다. > 목마와숙녀 님이 쓴 글입니다. > 제목 : 문의 > 입력시간부터 발생한 봉들로만 계산 input:시간1(093000); input:시간2(100000); 음봉비율은 시간1에서 시간2까지 발생한 전체봉에서 음봉비율(음봉/전체봉*100) 진입은 시간2 지나고부터 시작합니다. if 음봉비율>50 then sell(); 수식 부탁드립니다. 항상 고맙습니다.
프로필 이미지
목마와숙녀
2024-11-06
603
글번호 183469
시스템
답변완료

수식 문의 드립니다

(1) 식, Input : Period(20) ; var : DMIv(0),DP(0),DM(0); DMIv = DMI(Period); DP = DIPlus(Period); DM = DIMinus(Period); data2 를 이용하여 data2(DMIv 가 상승중 DP 가 DM을 상향시) 매수 data2 를 이용하여 data2(DP 가 DM을 하향시) 매도 (2) 식 rsi(9), STOCHASTIC(12,5,5)를 이용한 data2 식 부탁 드립니다. DATA2(STOCHASTIC(12,5,5)) 가 상승 중이고, data2(RSI(9)) 가 50 상향시 매수 data2(rsi(9)) 가 70 상향시 매도 (3)식 trix(10,7) , macd(12,26,9) 이용한 data2 식 data2( trix) 와 data2(madc) 가 상승 중 일 때 매수 data2(macd)가 dead cross에서 매도
프로필 이미지
기관장
2024-09-15
705
글번호 183468
시스템
답변완료

문의드립니다

특정일의 고가, 저가, 종가를 분봉에 표시하고 싶습니다 특정일이후의 고/저/종가가 아니라... 특정일 히루의 dayhigh, daylow, dayclose 를 분봉에 가로선으로 나오게 표시.. 감사합니다
프로필 이미지
러블리
2024-09-18
681
글번호 183467
지표

와우리 님에 의해서 삭제되었습니다.

프로필 이미지
와우리
2024-09-15
44
글번호 183466
지표