커뮤니티

예스랭귀지 Q&A

글쓰기

망고맨 님에 의해서 삭제되었습니다.

프로필 이미지
망고맨
2023-03-29
0
글번호 167658
시스템
답변완료

트레이딩뷰에 RSI 다이버젼스 수식

안녕하세요? 제가 웹이랑 유투브 다뒤졌는데 수식이 안나옵니다. 트레이딩뷰에 RSI 다이버젼스 수식을 영웅문 포맷으로 우선 알수 있을까요? 코드는 다음과 같다고 나옵니다. study(title="RSI Divergence", shorttitle="RSI Divergence") src_fast = close, len_fast = input(5, minval=1, title="Length Fast RSI") src_slow = close, len_slow = input(14,minval=1, title="Length Slow RSI") up_fast = rma(max(change(src_fast), 0), len_fast) down_fast = rma(-min(change(src_fast), 0), len_fast) rsi_fast = down_fast == 0 ? 100 : up_fast == 0 ? 0 : 100 - (100 / (1 + up_fast / down_fast)) up_slow = rma(max(change(src_slow), 0), len_slow) down_slow = rma(-min(change(src_slow), 0), len_slow) rsi_slow = down_slow == 0 ? 100 : up_slow == 0 ? 0 : 100 - (100 / (1 + up_slow / down_slow)) //plotfast = plot(rsi_fast, color=blue) //plotslow = plot(rsi_slow, color=orange) divergence = rsi_fast - rsi_slow plotdiv = plot(divergence, color = divergence > 0 ? lime:red, linewidth = 2) //band1 = hline(70,color=green) //band0 = hline(30,color=red) band = hline(0)
프로필 이미지
jinita
2023-03-29
1427
글번호 167657
지표
답변완료

사용자함수값 유지

사용자함수에서 1번 계산한 값을 당일 내내유지하고 싶습니다. 아래와 같이 했는데, k값이 당일첫봉(1분봉차트)을 제외하고는 계속 k=1의 값만 가지는것 같습니다. '진입수량' 사용자 함수는 계좌의 잔고를 바탕으로 수량을 계산해주는 함수이구요 (실전차트에 연동후 message로그 확인함) 제가 원하는건, 첫봉에 k값을 한번만 계산하고 그 다음부터는 그 값을 계속 k에 가지고 있게 하려는건데, 아래와 같이 하면 k값이 첫봉이후에는 1의 값만 가지고 있어서요. 어떻게 수정하면 될까요? -------------------------------------------------------------------- VARS: k(3) //당일 처음에 한번만 사용자함수안 '진입수량'을 계산하여 k에 입력함! if Bdate != Bdate[1] Then k = 진입수량 ; ElsE k = k[1];
프로필 이미지
건곤대
2023-03-29
983
글번호 167645
시스템
답변완료

엔벨로프

envelopeup(888,11)을 상향돌파하는 종목 검색식 부탁드려요,, 이미 돌파한지 한참 지난 종목 말구 오늘 돌파한 종목 검색식이요 ㅜ
프로필 이미지
anj
2023-03-29
768
글번호 167637
종목검색
답변완료

문의

데이타2(옵션)의 시가의 5틱위에 왓을때 데이타1에 횡선이 나오도록 표현할수 있나요
프로필 이미지
레전드
2023-03-29
702
글번호 167636
지표

anj 님에 의해서 삭제되었습니다.

프로필 이미지
anj
2023-03-29
0
글번호 167635
종목검색
답변완료

종목검색 문의

500일 저점추세선에(자동추세선 이용중) 닿은 종목을 찾는 종목검색식 부탁드려요,, 불가능하다면 비슷하게라도 만들어 주세요 ㅜ
프로필 이미지
anj
2023-03-28
1063
글번호 167634
종목검색
답변완료

수식 전환 부탁드립니다

trading view 수식, 예스트레이더 변환 부탁드립니다 study(title="Twin Range Filter", overlay=true) source = input(defval=close, title="Source") // Smooth Average Range per1 = input(defval=27, minval=1, title="Fast period") mult1 = input(defval=1.6, minval=0.1, title="Fast range") per2 = input(defval=55, minval=1, title="Slow period") mult2 = input(defval=2, minval=0.1, title="Slow range") smoothrng(x, t, m) => wper = t * 2 - 1 avrng = ema(abs(x - x[1]), t) smoothrng = ema(avrng, wper) * m smoothrng smrng1 = smoothrng(source, per1, mult1) smrng2 = smoothrng(source, per2, mult2) smrng = (smrng1 + smrng2) / 2 // Range Filter rngfilt(x, r) => rngfilt = x rngfilt := x > nz(rngfilt[1]) ? x - r < nz(rngfilt[1]) ? nz(rngfilt[1]) : x - r : x + r > nz(rngfilt[1]) ? nz(rngfilt[1]) : x + r rngfilt filt = rngfilt(source, smrng) upward = 0.0 upward := filt > filt[1] ? nz(upward[1]) + 1 : filt < filt[1] ? 0 : nz(upward[1]) downward = 0.0 downward := filt < filt[1] ? nz(downward[1]) + 1 : filt > filt[1] ? 0 : nz(downward[1]) hband = filt + smrng lband = filt - smrng longCond = bool(na) shortCond = bool(na) longCond := source > filt and source > source[1] and upward > 0 or source > filt and source < source[1] and upward > 0 shortCond := source < filt and source < source[1] and downward > 0 or source < filt and source > source[1] and downward > 0 CondIni = 0 CondIni := longCond ? 1 : shortCond ? -1 : CondIni[1] long = longCond and CondIni[1] == -1 short = shortCond and CondIni[1] == 1 // Plotting plotshape(long, title="Long", text="Long", style=shape.labelup, textcolor=color.black, size=size.tiny, location=location.belowbar, color=color.lime, transp=0) plotshape(short, title="Short", text="Short", style=shape.labeldown, textcolor=color.white, size=size.tiny, location=location.abovebar, color=color.red, transp=0) // Alerts alertcondition(long, title="Long", message="Long") alertcondition(short, title="Short", message="Short")
프로필 이미지
seayun1
2023-03-28
1485
글번호 167633
지표
답변완료

도움부탁드립니다

키움지표을 예스트레이드로변경부탁드립니다. 수식1:Ra=rsi(period1,이평종류); valuewhen(1,crossup(Ra,K1),가격1) 수식2:Ra=rsi(period2,이평종류); valuewhen(1,crossdown(Ra,K2),가격1) 수식3:Ra=rsi(period1,이평종류); valuewhen(1,crossup(Ra,K1),가격2) 수식4:Ra=rsi(period2,이평종류); valuewhen(1,crossdown(Ra,K2),가격2) 지표조건:Period1:14 Period2:14 k1:30 k2:70 가격1:(고가+저가)/2 가격2:(고가+저가+종가)/3 이평종류:단순
프로필 이미지
렉스턴
2023-03-28
1564
글번호 167632
지표
답변완료

문의

당일고점대비 3%인 가격을 차트에 표시하고 싶습니다.. 어찌해야 하나요?
프로필 이미지
엉덩공주
2023-03-28
1276
글번호 167631
지표