커뮤니티

예스랭귀지 Q&A

글쓰기
답변완료

[공지] 예스랭귀지 AI 어시스턴트, '예스나 AI' 출시 및 무료 체험 안내

안녕하세요, 예스스탁 입니다.복잡한 수식 공부 없이 여러분의 아이디어를 말하면 시스템 트레이딩 언어 예스랭귀지로 작성해주는 서비스예스나 AI(YesNa AI)가 출시되었습니다.지금 예스나 AI를 직접 경험해 보실 수 있도록 20크레딧(질문권 20회)를 무료로 증정해 드리고 있습니다.바로 여러분의 아이디어를 코드로 변환해보세요.--------------------------------------------------🚀 YesNa AI 핵심 기능- 지표식/전략식/종목검색식 생성: 자연어로 요청하면 예스랭귀지 문법에 맞는 코드를 작성합니다.- 종목검색식 변환 지원: K증권의 종목 검색식을 예스랭귀지로 변환 지원합니다.- 컴파일 검증: 작성된 코드가 실행 가능한지 컴파일러를 통해 문법 검증을 거쳐 결과물을 제공합니다.상세한 서비스 개요 및 활용 방법은 [서비스 소개 페이지]에서 확인하실 수 있습니다.▶ 서비스 소개 페이지: 바로가기서비스 사용 유의사항 및 결제 환불정책은 [이용약관]을 참고 부탁드립니다.▶ 서비스 이용약관: 바로가기💬 이용 문의사용 중 문의사항은 [프로그램 사용법 Q&A] 게시판에서 [예스나 AI] 카테고리를 설정 후 문의해 주시면 상세히 안내해 드리겠습니다.--------------------------------------------------앞으로도 AI를 활용한 다양한 트레이딩 기능들을 지속적으로 선보일 예정입니다.많은 관심과 기대 부탁드립니다.
프로필 이미지
예스스탁
2026-02-27
8277
글번호 230811
지표
답변완료

예스로 부탁합니다.

트뷰에서 알게된 지표인데 예스 수식으로 부탁합니다. 미리감사드립니다. //version=5 //author: mladen //rebound arrows and TMA angle caution: Ale //rewritten from MQL5 to Pine: Brylator indicator("TMA Centered Bands Indicator", "TMA v1.0 Gaga", overlay = true, max_lines_count = 500, max_labels_count = 500) //INPUTS var GRP1 = "Parameters" HalfLength = input.int(44, "Centered TMA half period", group = GRP1) string PriceType = input.string("Weighted", "Price to use", options = ["Close", "Open", "High", "Low", "Median", "Typical", "Weighted", "Average"], group = GRP1) AtrPeriod = input.int(120, "Average true range period", group = GRP1) AtrMultiplier = input.float(2, "Average true range multiplier", group = GRP1) TMAangle = input.int(4, "Centered TMA angle caution", group = GRP1) // APPEARANCE (&#3648;&#3614;&#3636;&#3656;&#3617;&#3605;&#3633;&#3623;&#3648;&#3621;&#3639;&#3629;&#3585;&#3586;&#3609;&#3634;&#3604;&#3649;&#3621;&#3632;&#3586;&#3657;&#3629;&#3588;&#3623;&#3634;&#3617; BUY/SELL) var GRP4 = "Appearance" arrowSizeOpt = input.string("Large", "Arrow size", options = ["Tiny", "Small", "Normal", "Large", "Huge"], group = GRP4) showBuySellText = input.bool(true, "Show BUY/SELL text on arrows", group = GRP4) buyText = input.string("BUY", "Buy text", inline = "txt", group = GRP4) sellText = input.string("SELL", "Sell text", inline = "txt", group = GRP4) // map &#3586;&#3609;&#3634;&#3604; arrowSize = switch arrowSizeOpt "Tiny" => size.tiny "Small" => size.small "Normal" => size.normal "Large" => size.large => size.huge //VARIABLES float tmac = na float tmau = na float tmad = na var float pastTmac = na //from the previous candle var float pastTmau = na var float pastTmad = na float tmau_temp = na //before looping float tmac_temp = na float tmad_temp = na float point = syminfo.pointvalue //NEEDS MORE TESTS bool last = false //checks if a loop is needed var string alertSignal = "EMPTY" //needed for alarms to avoid repetition //COLORS var GRP2 = "Colors" var color colorBuffer = na color colorDOWN = input.color(color.new(color.red, 0), "Bear", inline = "5", group = GRP2) color colorUP = input.color(color.new(color.green, 0), "Bull", inline = "5", group = GRP2) color colorBands = input.color(color.new(#b2b5be, 0), "Bands", inline = "5", group = GRP2) bool cautionInput = input.bool(true, "Caution label", inline = "6", group = GRP2) //ALERTS var GRP3 = "Alerts (Needs to create alert manually after every change)" bool crossUpInput = input.bool(false, "Crossing up", inline = "7", group = GRP3) bool crossDownInput = input.bool(false, "Crossing down", inline = "7", group = GRP3) bool comingBackInput = input.bool(false, "Coming back", inline = "7", group = GRP3) bool onArrowDownInput = input.bool(false, "On arrow down", inline = "8", group = GRP3) bool onArrowUpInput = input.bool(false, "On arrow up", inline = "8", group = GRP3) //CLEAR LINES a_allLines = line.all if array.size(a_allLines) > 0 for p = 0 to array.size(a_allLines) - 1 line.delete(array.get(a_allLines, p)) //GET PRICE Price(x) => float price = switch PriceType "Close" => close[x] "Open" => open[x] "High" => high[x] "Low" => low[x] "Median" => (high[x] + low[x]) / 2 "Typical" => (high[x] + low[x] + close[x]) / 3 "Weighted" => (high[x] + low[x] + close[x] + close[x]) / 4 "Average" => (high[x] + low[x] + close[x] + open[x])/ 4 price //MAIN for i = HalfLength to 0 //ATR atr = 0.0 for j = 0 to AtrPeriod - 1 atr += math.max(high[i + j + 10], close[i + j + 11]) - math.min(low[i + j + 10], close[i + j + 11]) atr /= AtrPeriod //BANDS sum = (HalfLength + 1) * Price(i) sumw = (HalfLength + 1) k = HalfLength for j = 1 to HalfLength sum += k * Price(i + j) sumw += k if (j <= i) sum += k * Price(i - j) sumw += k k -= 1 tmac := sum/sumw tmau := tmac+AtrMultiplier*atr tmad := tmac-AtrMultiplier*atr //ALERTS if i == 0 //Only on a real candle if (high > tmau and alertSignal != "UP") //crossing up band if crossUpInput == true //checks if activated alert("Crossing up Band") //calling alert alertSignal := "UP" //to avoid repeating else if (low < tmad and alertSignal != "DOWN") //crossing down band if crossDownInput == true alert("Crossing down Band") alertSignal := "DOWN" else if (alertSignal == "DOWN" and high >= tmad and alertSignal != "EMPTY") //back from the down band if comingBackInput == true alert("Coming back") alertSignal := "EMPTY" else if (alertSignal == "UP" and low <= tmau and alertSignal != "EMPTY") //back from the up band if comingBackInput == true alert("Coming back") alertSignal := "EMPTY" //CHANGE TREND COLOR if pastTmac != 0.0 if tmac > pastTmac colorBuffer := colorUP if tmac < pastTmac colorBuffer := colorDOWN //SIGNALS reboundD = 0.0 reboundU = 0.0 caution = 0.0 if pastTmac != 0.0 if (high[i + 1] > pastTmau and close[i + 1] > open[i + 1] and close < open) reboundD := high + AtrMultiplier * atr / 2 if (tmac - pastTmac > TMAangle * point) caution := reboundD + 10 * point if (low[i + 1] < pastTmad and close[i + 1] < open[i + 1] and close > open) reboundU := low - AtrMultiplier * atr / 2 if (pastTmac - tmac > TMAangle * point) caution := reboundU - 10 * point //LAST REAL if barstate.islast and i == HalfLength last := true tmau_temp := tmau tmac_temp := tmac tmad_temp := tmad //DRAW HANDICAPPED BANDS if barstate.islast and i < HalfLength line.new(bar_index - (i + 1), pastTmau, bar_index - (i), tmau, width = 2, style = line.style_dotted, color = colorBands) line.new(bar_index - (i + 1), pastTmac, bar_index - (i), tmac, width = 2, style = line.style_dotted, color = colorBuffer) line.new(bar_index - (i + 1), pastTmad, bar_index - (i), tmad, width = 2, style = line.style_dotted, color = colorBands) //DRAW SIGNALS (&#3621;&#3641;&#3585;&#3624;&#3619;&#3651;&#3627;&#3597;&#3656;&#3586;&#3638;&#3657;&#3609; + &#3617;&#3637;&#3588;&#3635;&#3623;&#3656;&#3634; SELL/BUY) if reboundD != 0 txtDown = showBuySellText ? "▼₩n" + sellText : "▼" label.new(bar_index - (i), reboundD, txtDown, color = na, style = label.style_label_center, textcolor = colorDOWN, size = arrowSize, textalign = text.align_center) if i == 0 and onArrowDownInput == true //alert alert("Down arrow") if caution != 0 and cautionInput == true label.new(bar_index - (i), reboundD, color = colorUP, style = label.style_xcross, size = size.tiny, textcolor = na) if reboundU != 0 txtUp = showBuySellText ? "▲₩n" + buyText : "▲" label.new(bar_index - (i), reboundU, txtUp, color = na, style = label.style_label_center, textcolor = colorUP, size = arrowSize, textalign = text.align_center) if i == 0 and onArrowUpInput == true //alert alert("UP arrow") if caution != 0 and cautionInput == true label.new(bar_index - (i), reboundU, color = colorDOWN, style = label.style_xcross, size = size.tiny, textcolor = na) //SAVE HISTORY pastTmac := tmac pastTmau := tmau pastTmad := tmad //LOOP IS ONLY FOR HANDICAPPED if barstate.islast != true break //DRAW REAL BANDS plot(last ? tmau_temp : tmau, title = "TMA Up", color = colorBands, linewidth=1, style = plot.style_line, offset = -HalfLength) plot(last ? tmac_temp : tmac, title = "TMA Mid", color = colorBuffer, linewidth=1, style = plot.style_line, offset = -HalfLength) plot(last ? tmad_temp : tmad, title = "TMA Down", color = colorBands, linewidth=1, style = plot.style_line, offset = -HalfLength)
프로필 이미지
as8282
2025-08-10
2143
글번호 193113
지표
답변완료

종목검색식 부탁드립니다

1. 일봉기준 차트에서, 주봉 20 이평선 (단순) 을 표시하여 (그어서) 일봉 캔들이 양봉으로 주봉 20이평선을 몸통으로 관통(종가로 돌파)하는 종목검색식 부탁드립니다.
프로필 이미지
일지매7
2025-08-10
445
글번호 193112
종목검색
답변완료

분봉상거래대금

수고 많으십니다. 분봉상 1분봉상 거래대금이 1억원 이상 20봉 영봉까지 아예 없었던 종목을 검색하고 싶습니다. input을 사용하여 20(기간)을 조정 가능하게 부탁드립니다. 감사합니다.
프로필 이미지
제시립뭐
2025-08-10
446
글번호 193111
종목검색
답변완료

수식전환

수고많으십니다 아래 타사수식 예스로 전환 부탁드립니다 분봉챠트에서 cnt=countsince (date==date(1)&& date==date(2)&& date!=date(3),C>Dayopen()&& C(1)<Dayopen()); S=countsince(date!=date(1),C<Dayopen()); cnt==1&&cnt(1)==0&&S>1
프로필 이미지
트라이
2025-08-10
455
글번호 193110
종목검색
답변완료

지표 문의

안녕하세요, 아래 수식 요청 드립니다. ;;전일 범위를 기준으로 계산한 두 레벨(Y1=14.6%, Y8=85.4%)에 “고정 수평 라인”을 생성해 현재가가 라이을 크로스 하기 전에는 라인을 유지(여러 날 동안 유지도 가능) 라인을 크로스 하면 즉시 삭제해 주는 지표 부탁 드립니다. 기준값 전일 고가 YH = DayHigh(1) 전일 저가 YL = DayLow(1) 전일 범위 R = YH - YL Y1 = YL + R×0.146 (하단) Y8 = YL + R×0.854 (상단) 혹시 당일의 시가가 전일의 고가/저가 갭으로 돌파시에도 Y8,Y1 을 그렸으면 합니다. 라인은 여러 개 누적 가능하고 현재가가 크로스 하기 전까지는 유지되어야 하고요, 라인 오른쪽 상단에 가격도 표시 되었으면 합니다. 추가로 한시간 봉의 시가가 시가 저가 혹은 시가 고가인지를 매 시간 3분에 체크하여 시가 저가/고가 일 경우 라인을 그리고, 이 라인이 현재가가 크로스 하기 전까지 유지 되었으면 합니다.
프로필 이미지
나뽀리
2025-08-10
796
글번호 193109
지표
답변완료

종목검색식 부탁드립니다

X1 = V(1) >= V(2) *5; X2 = V <= V(1) * 0.25; X3 = (O/AVG(C,5) * 100) >= 90; X4 = (O/AVG(C,5) * 100) <= 110; X5 = (C(1)/O(1)-1) * 100 >=5; X1 AND X2 AND X3 AND X4 AND X5
프로필 이미지
밤의선수
2025-08-09
435
글번호 193108
종목검색
답변완료

검색식 부탁 드려요

아래 수식을 참고하여 , 1. 수식4)가 전일보다 상승한 종목 검색식 부탁드립니다. 2. 수식5)가 전일보다 상승한 종목 검색식 부탁드려요 3. 수식4) 가 수식5)를 골든크로스 할때 종목검색식 부탁드립니다 4. 수식4) 가 수식5) 의 위에 있을때 종목검색식 부탁드려요. --------아래----- (수식1) tenkan=If(Sum(거래량, ConvPeriod) > 0, Sum(((고가 + 저가) / 2) * 거래량, ConvPeriod) / Sum(거래량, ConvPeriod), (Max(고가, ConvPeriod) + Min(저가, ConvPeriod)) / 2); (수식2) kijun = If(Sum(거래량, BasePeriod) > 0, Sum(((고가 + 저가) / 2) * 거래량, BasePeriod) / Sum(거래량, BasePeriod), (Max(고가, BasePeriod) + Min(저가, BasePeriod)) / 2); (수식3) shift(close,-25) (수식4) spanA = (tenkan + kijun) / 2; //SHIFT(spanA,25) (수식5) spanB = tenkan=If(Sum(거래량, SpanBPeriod) > 0, Sum(((고가 + 저가) / 2) * 거래량, SpanBPeriod) / Sum(거래량, SpanBPeriod), (Max(고가, SpanBPeriod) + Min(저가, SpanBPeriod)) / 2); //SHIFT(spanB,25) - 지표조건설정 ConvPeriod : 9 BasePeriod : 26 SpanBPeriod : 52 Shift : 26
프로필 이미지
일지매7
2025-08-11
508
글번호 193107
종목검색
답변완료

문의 드립니다.

코인에서 매수용으로 사용하려고 하는데요. 수량을 빼고 금액을 입력할 수 있도록 추가 부탁드립니다. input : Price(3480.0),xPrice(3486.0),수량(1); if crossup(C,price) Then buy("b",OnClose,Def,수량); if MarketPosition == 1 Then { if CrossUp(C,xPrice) Then ExitLong("bx1"); if CrossDown(C,Price) Then ExitLong("bx2"); } SetStopEndofday(243000);
프로필 이미지
선물대장
2025-08-09
520
글번호 193106
시스템
답변완료

문의

연봉의엔벨로프를 일봉에 그릴수 있게 해주셔요 종목검색 일봉상 연봉엔벨로프하한선을 돌파한 종목을 검색할수 있게 해주셔요
프로필 이미지
엉덩공주
2025-08-09
437
글번호 193105
지표