커뮤니티

예스랭귀지 Q&A

글쓰기

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

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

안녕하세요 차트 수식문의드립니다.

수고하십니다. 수식문의드립니다. 일봉기준으로 특정일(예:20240220)을 변수로 입력하여 그 특정일의 시가를 차트에 표시하고 그 특정일 이후에 나온 봉중 가장 높은 고가와 가장 낮은 저가를 차트에 표시한다음 특정일의 시가대비 고가의 상승률을 특정일의 시가대비 저가의 하락률을 차트에 표시하고 싶습니다. 답변부탁드립니다. 감사합니다!
프로필 이미지
수다리
2024-02-20
1096
글번호 176807
검색
답변완료

수고하십니다

1) 0봉전 . 120봉전 중 최저가 2) 0봉전 60봉전 중 최고가 종목 검색 부탁드립니다 감사합니다
프로필 이미지
쌍둥이
2024-02-20
1227
글번호 176806
검색
답변완료

도움요청합니다

a=predayhigh(); o < a and h > a and avg(v,1)>100000 전일고가선 아래에서 위로돌파 1분거래량10만주이상 랭귀지에 사용하게 도와주새요
프로필 이미지
gksk
2024-02-20
890
글번호 176805
종목검색
답변완료

문의 드립니다

input : StartTime(80000),EndTime(40000); input : 익절틱수(400),손절틱수(200); var : Tcond(False),entry(0); Variables: Mom(0); IF Endtime > starttime Then SetStopEndofday(Endtime); Else { if sDate != sDate[1] Then SetStopEndofday(Endtime); } if (sdate != sdate[1] and stime >= StartTime) or (sdate == sdate[1] and stime >= StartTime and stime[1] < StartTime) Then { Tcond = true; IF Endtime <= starttime Then { SetStopEndofday(0); } } if (sdate != sdate[1] and stime >= EndTime) or (sdate == sdate[1] and stime >= EndTime and stime[1] < EndTime) Then { Tcond = False; } if Tcond == true Then { if L ==lowest(L,2) and highest(H,2) >= lowest(L,2)+PriceScale*1 Then { Buy("b",AtStop,(highest(H,2)+lowest(L,2))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); } if H == highest(H,2) and lowest(L,2) <= highest(H,2)+PriceScale*1 Then { Sell("s",AtStop,(lowest(L,2)+highest(H,2))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b1",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s1",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b2",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s2",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,2) and highest(H,2) >= lowest(L,2)+PriceScale*1 Then { Buy("b3",AtStop,(highest(H,2)+lowest(L,2))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,2) and lowest(L,2) <= highest(H,2)+PriceScale*1 Then { Sell("s3",AtStop,(lowest(L,2)+highest(H,2))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b4",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s4",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b5",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s5",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,2) and highest(H,2) >= lowest(L,2)+PriceScale*1 Then { Buy("b6",AtStop,(highest(H,2)+lowest(L,2))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,2) and lowest(L,2) <= highest(H,2)+PriceScale*1 Then { Sell("s6",AtStop,(lowest(L,2)+highest(H,2))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b7",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s7",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b8",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s8",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,2) and highest(H,2) >= lowest(L,2)+PriceScale*1 Then { Buy("b9",AtStop,(highest(H,2)+lowest(L,2))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,2) and lowest(L,2) <= highest(H,2)+PriceScale*1 Then { Sell("s9",AtStop,(lowest(L,2)+highest(H,2))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b10",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s10",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); if L ==lowest(L,1) and highest(H,3) >= lowest(L,2)+PriceScale*10 Then { Buy("b11",AtStop,(highest(H,3)+lowest(L,1))/2); } if MarketPosition == 1 and BarsSinceEntry == 2 Then ExitShort(); if H == highest(H,1) and lowest(L,3) <= highest(H,2)+PriceScale*10 Then { Sell("s11",AtStop,(lowest(L,3)+highest(H,1))/2); } if MarketPosition == -1 and BarsSinceEntry == 2 Then ExitLong(); SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); 위 수식어의 해외선물에서 4가지 변경된 수식어를 부탁 드립니다. 1. 전일잔고를 아침 7시40분 ~8시사이 업데이트 시간 이후 특정한 시간에 청산되는 변경된 수식어 2. startTime에 진입후 체결과 endTime에 잔고가 청산되는 변경된 수식어 3. 익절과 손절후 잔고가 없는 변경된 수식어 4. 익절후 매매정지
프로필 이미지
푸른
2024-02-21
1018
글번호 176804
시스템
답변완료

지표식좀 부탁합니다

안녕하세요 이미지에 보시는것 처럼 매수 매도 신호를 사용하고 있습니다 중간선을 차트에 나오게 만들고 십네요 1. 주가가 5일선 아래에서 놀다가 5일선 돌파하고 조건이 맞으면 매수가 나오고 2. 주가가 5일선 위에서 놀다가 5일선 이탈하고 조건이 맞으면 매도가 나오고 있습니다 1번 매수 나오기전 5일선 아래 저점 2번 매도 나오기전 5일선 위 고점 이 1번2번의 중간선을 차트에 나오게 했으면합니다
프로필 이미지
상영중
2024-02-20
867
글번호 176803
지표
답변완료

라운드 피겨 가격

감사합니다 가격 호가범위가 510000원 520000원 처럼 변할 때 호가의 만단위 10000, 20000, ~ 가격 호가범위가 11000윈 12000원 처럼 변할 때 호가의 천단위 1000, 2000, 3000 ~ 가격 호가범위가 3100원 3200원 처럼 변할 때 호가의 백단위 100, 200, 300 ~ 가격 호가범위가 500원 600원처럼 변할 딱 호가의 십단위 500, 600 ~ 위 처럼 각 호가 단위의 십단위, 백단위, 천단위, 만단위, 십만단위의 일명 라운드 피겨가격을 자동/수동으로 그리고 싶습니다. 호가변동과 무관하게 지표만 그려도 되고 호가가 종가상으로 라운드 피겨가격을 돌파했을 때 지표를 그려도 됩니다 라운드 피겨 가격 개념 우리가 라운드 피겨라고 부르는 단어는 사실 라운드 넘버 (Round number)로 사용되고 있습니다. 라운드 넘버의 뜻은 '주어진 자릿수에서 하나 이상의 0으로 끝나는 숫자 들을 비공식적으로 부르는 것'입니다. 713이라는 숫자보 다는 710이, 710보다는 700이 더 라운드 넘버에 가깝습 니다. 즉 100, 500, 800, 1000, 10000 같이 딱딱 떨어지 는 숫자들을 지칭합니다. 1 Round 사용자 함수를 만들고 싶습니다. 위의 개념과 유사한 트레이딩 뷰 지표를 찾아봤습니다. 변환하여 쓸 수 있으면 좋겠습니다. 인서트 영어는 쓰기금지 되어있다기에 한글로 써봅니다. 2 Round Number Levels // This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/ // &#169; melodicfish //@version=5 indicator("Round Number Levels",overlay = true,max_labels_count = 101,max_lines_count = 101) incrementVal=input.float(defval=500, title="Unit Place Rounding Value", tooltip = "The Unit Place that a number will be rounded and distance between rounded levels. Example Value setting of 100 and a price of 225.00 would result in a line level value of 200.00; Where a price of 265.00 would result in a line level value of 300 with the same value setting of 100") lQty=input.int(defval=2,minval=1,maxval=50, title="Line Amount",tooltip = "Each Line Amount increase will add a line level above and below baseline level; Baseline = line nearest to price) ") offset=input.int(defval=50,minval=0, maxval=490,step=10, title="Line Price Horizontal Offset",inline = "a") textCol=input.color(defval = color.white,title="Price Label Text Color",tooltip = "Use Horizontal Offset to adjust the X position of the price labels. To hide price labels disable Labels on the style tab",inline = "a") belowColor=input.color(defval = color.blue,title="Line Color Below price",inline="b") aboveColor=input.color(defval = color.orange,title="Line Color Above price",inline="b") ext=input.string(defval = "To Right",options = ["To Right","Both"],title="Extend Line: ") float iv= incrementVal lQty:=lQty+1 var lines=array.new_line(lQty*2) var labels=array.new_label(lQty*2) var line baseLine=na RoundValue(value) => math.round(value / iv) * iv baseVal=RoundValue(close) if barstate.isconfirmed and baseVal!= baseVal[1] for i = 0 to (lQty*2) - 1 line.delete(array.get(lines,i)) label.delete(array.get(labels,i)) lines:=array.new_line(lQty*2) labels:=array.new_label(lQty*2) for j = 0 to lQty - 1 newLine=line.new(bar_index,baseVal+(j*iv),bar_index+1,baseVal+(j*iv),extend=ext=="Both"?extend.both:extend.right,color=close>baseVal+(j*iv)?belowColor:aboveColor) newLabel=label.new(bar_index+1+offset,baseVal+(j*iv),text=str.tostring(baseVal+(j*iv)),style= label.style_none,textcolor = textCol, textalign=text.align_right) array.인서트(lines,j,newLine) array.인서트(labels,j,newLabel) for k = 1 to lQty - 1 newLine=line.new(bar_index,baseVal-(k*iv),bar_index+1,baseVal-(k*iv),extend=ext=="Both"?extend.both:extend.right,color=belowColor) newLabel=label.new(bar_index+1+offset,baseVal-(k*iv),text=str.tostring(baseVal-(k*iv)),style= label.style_none,textcolor = textCol, textalign=text.align_right) array.인서트(lines,k+lQty,newLine) array.인서트(labels,k+lQty,newLabel) else if barstate.isconfirmed and baseVal== baseVal[1] line.set_color(array.get(lines,0),color=close>baseVal?belowColor:aboveColor) for l = 0 to (lQty*2)-1 label.set_x(array.get(labels,l),bar_index+1+offset) 3 Round Number Zones. // This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/ // &#169; trading-guide //@version=5 indicator("Round Number Zones", overlay=true) line_col = input(color.gray, title ="Line color") line_width = input.int(2, title = "Line width", minval = 1, maxval = 5) line_count = input.int(title="Line count", defval=10) line_count_2 = math.floor(line_count / 2) // Symbol 1 : EURUSD default show_sym_1 = input.bool(title="Show", defval=true, inline="2") sym_1 = input.symbol("EURUSD",title=" ", inline="2") sym_1_steps = input.float(title="+/-", defval=0.001, inline="2") sym_1_sec = request.security(sym_1,timeframe.period, close) sym_1_use_custom_price = input.bool(title="Custom Price", defval=false, inline="3") sym_1_custom_price = input.float(title="", defval=1.08, inline="3") // Symbol 2 : GOLD default show_sym_2 = input.bool(title="Show", defval=true, inline="4") sym_2 = input.symbol("GOLD",title=" ", inline="4") sym_2_steps = input.float(title="+/-", defval=5, inline="4") sym_2_sec = request.security(sym_2,timeframe.period, close) sym_2_use_custom_price = input.bool(title="Custom Price", defval=false, inline="5") sym_2_custom_price = input.float(title="", defval=1900, inline="5") // Symbol 3 : US30 default show_sym_3 = input.bool(title="Show", defval=true, inline="6") sym_3 = input.symbol("US30",title=" ", inline="6") sym_3_steps = input.float(title="+/-", defval=50, inline="6") sym_3_sec = request.security(sym_3,timeframe.period, close) sym_3_use_custom_price = input.bool(title="Custom Price", defval=false, inline="7") sym_3_custom_price = input.float(title="", defval=3500, inline="7") draw_line(sym, show, steps, custom, custom_price) => if sym == syminfo.prefix + ":" +syminfo.ticker and show for i = 0 to line_count - 1 price = custom ? custom_price : close step = math.ceil(price / steps) * steps + (i * steps) - (line_count_2 * steps) line.new(bar_index, step, bar_index - 1, step, xloc=xloc.bar_index, extend=extend.both, color=line_col, width=line_width, style=line.style_dotted) draw_line(sym_1, show_sym_1, sym_1_steps, sym_1_use_custom_price, sym_1_custom_price) draw_line(sym_2, show_sym_2, sym_2_steps, sym_2_use_custom_price, sym_2_custom_price) draw_line(sym_3, show_sym_3, sym_3_steps, sym_3_use_custom_price, sym_3_custom_price)
프로필 이미지
jdavid
2024-02-21
1415
글번호 176797
지표
답변완료

수식 부탁드림니다

아래의 수식 지표 부탁드림니다 항상 고맙습니다 ------------------------------------------------ HH=HIGHEST(H, P60); V4=(V(1)+V(2)+V(3)+V(4) )/4; CGE=100*(C(1)-HH)/HH; BOE= C(1)< C(2) AND CGE<2 AND V>V10000 AND C>C(1) AND V>V4; BAK=VALUEWHEN(1, BOE, H); SHIFT(BAK, 1) -------------------------------------------------
프로필 이미지
아트키노
2024-02-20
910
글번호 176796
지표
답변완료

예스트레이더의 차트화면

85883문의 봐 주세요. 저의 질문이 잘못되었읍니다. RSI(14)가 65 상향돌파 및 30하향돌파가 아니라 65이상은 모두 황금색, 30미만은 모두 그레이로 차트가격화면에 표시하려는 것이었읍니다. 죄송합니다만 이렇게 수정해주실수 있나요?
프로필 이미지
ksks
2024-02-20
949
글번호 176795
지표
답변완료

수식변경부탁드려요 도사님.

1 if long Then { tx = Text_New(sDate,sTime,L,"Long"); Text_SetStyle(tx,2,0); Text_SetColor(tx,Lime); Buy("b",OnClose,Def,5); } if short Then { tx = Text_New(sDate,sTime,H,"Short"); Text_SetStyle(tx,2,1); Text_SetColor(tx,Red); Sell("s",OnClose,Def,5); } SetStopEndofday(150000); 2 if long Then { tx = Text_New(sDate,sTime,L,"Long"); Text_SetStyle(tx,2,0); Text_SetColor(tx,Lime); Buy("b",OnClose,Def,5); } if short Then { tx = Text_New(sDate,sTime,H,"Short"); Text_SetStyle(tx,2,1); Text_SetColor(tx,Red); Sell("s",OnClose,Def,5); } if MarketPosition == 1 and BarsSinceEntry == 1 Then ExitLong("bx"); if MarketPosition == -1 and BarsSinceEntry == 1 Then ExitShort("sx"); SetStopEndofday(150000); ///////////////////////////////////////////////////////////////////////// 1.텍스트발생시 분봉시가기준 진입 --> 다음봉 종가기준 청산 도사님 , 부탁드립니다. 텍스트발생 후 5계약 진입시 분봉 종가 기준으로 진입을 하게되어있는데, 시가기준으로 바꿀수 있을까요? 안된다면 다음봉 시작가로 부탁드립니다. (손실로스 진입단가 강제청산 및 틱수설정)
프로필 이미지
아이덜
2024-02-20
861
글번호 176793
시스템