커뮤니티

예스랭귀지 Q&A

글쓰기
답변완료

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

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

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

프로필 이미지
wscamtk
2022-09-08
18
글번호 162079
지표

시고르시고르 님에 의해서 삭제되었습니다.

프로필 이미지
시고르시고르
2022-09-08
4
글번호 162078
지표
답변완료

문의드립니다.

감사합니다. 아래수식 수정해주시면 감사하겠습니다. 아래 수식에 강제청산 200틱 손절을 포함해주시고, 강제청산후 다음 진입신호가 같은 방향이면 진입하지 않고, 3번째 진입신호부터는 같은방향도 진입가능하게 부탁드립니다. 강제청산후 다음 진입신호가 다른 방향이면 무조건 진입가능 합니다. 감사합니다.... input : StartTime(83000),EndTime(65000); Input : rsiP(9),과매수(80),과매도(20),maP(120); var : RSIV(0),mav(0); var : Tcond(false); RSIV = RSI(rsiP); mav = ma(c,mav); IF Endtime > starttime Then SetStopEndofday(Endtime); Else { if sDate != sDate[1] Then SetStopEndofday(Endtime); } if (sdate != sdate[1] and stime >= EndTime) or (sdate == sdate[1] and stime >= EndTime and stime[1] < EndTime) Then Tcond = False; 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 Tcond == true Then { if MarketPosition >= 0 and CrossUp(RSIV,과매수) and IsExitName("sx1",1) == False Then Sell("s"); if MarketPosition == -1 Then { if CountIf(CrossUp(RSIV,과매수),BarsSinceEntry) == 4 Then ExitShort("sx1"); if CrossUp(C,mav) Then ExitShort("sx2"); } if MarketPosition <= 0 and CrossDown(RSIV,과매도) and IsExitName("bx1",1) == False Then Buy(); if MarketPosition == 1 Then { if CountIf(CrossDown(RSIV,과매도),BarsSinceEntry) == 4 Then ExitLong("bx1"); if CrossDown(C,mav) Then ExitShort("bx2"); } }
프로필 이미지
하늘북
2022-09-07
986
글번호 162077
시스템

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

프로필 이미지
회원
2022-09-08
167
글번호 162076
지표
답변완료

2개 전략

안녕하세요~~^^ 동일 종목에서 2개 전략 사용시(buy, sell) 같은 변수명이 있으면 에러가 발생하나요?
프로필 이미지
코퍼
2022-09-07
1213
글번호 162073
시스템
답변완료

안녕하세요

안녕하세요 1. 아래 수식은 진입가 대비 10% 수익시 1계약 청산식입니다. 진입한(보유) 수량의 % 비율로 청산수식을 수정부탁드립니다. 예시는 보유 수량의 50%씩 두번 분할청산 되는 수식으로 부탁드려요. ExitLong("bp1",AtLimit,EntryPrice*1.1,def,10); 2. 아래 수식으로 손절을 하는데요 분할진입시 익절,손절이 개별 진입시점기준으로 분산됨니다. ex) 손절 1%예시 1차 진입가 100 일때 99 손절 , 2차 진입가 200 일때 198 손절 손절도 분할로 익절도 동일하게 분할 처리 됨니다. 익절,손절을 평균가로 하는 예제수식 부탁드립니다. LC(손절변수) SetStopLoss(LC,PercentStop); ----------------------------------------------------------------- If MarketPosition <= 0 and value1 == 1 and Condition1 == true Then Buy("B1",AtStop,고[2,1]-PriceScale*a,1); if MarketPosition == 1 Then { if L > EntryPrice*0.99 Then Buy("bb2",AtLimit,EntryPrice*0.99,1); if L > EntryPrice*0.98 Then Buy("bb3",AtLimit,EntryPrice*0.98,1); if L > EntryPrice*0.97 Then Buy("bb4",AtLimit,EntryPrice*EntryPrice*0.97,1); if L > EntryPrice*0.96 Then Buy("bb5",AtLimit,EntryPrice*EntryPrice*0.96,1); } if MarketPosition == 1 Then { if H < EntryPrice*1.02 Then ExitLong("bp1",AtLimit,EntryPrice*1.02,def,1); if H < EntryPrice*1.04 Then ExitLong("bp2",AtLimit,EntryPrice*1.04,def,1); if H < EntryPrice*1.06 Then ExitLong("bp3",AtLimit,EntryPrice*1.06,def,1); if H < EntryPrice*1.08 Then ExitLong("bp4",AtLimit,EntryPrice*1.08,def,1); if H < EntryPrice*1.10 Then ExitLong("bp5",AtLimit,EntryPrice*1.10,def,1); } SetStopLoss(LC,PercentStop); 감사합니다.
프로필 이미지
상중하
2022-09-07
1251
글번호 162051
시스템
답변완료

문의드립니다

var11=var11+Upticks; var12=var12+Downticks; var13=var11-var12; 이런식으로 업틱과 다운틱의 차이를 구하려고 합니다. 틱챠트에서 최초 10개 봉의 var13 평균값을 구하는 수식 부탁드립니다
프로필 이미지
고스트
2022-09-07
1021
글번호 162050
시스템
답변완료

문의 드립니다

input : 익절틱수(160),손절틱수(30); var1 = ma(C,10); Var2 = ma(C,1); if NextBarSdate != sDate and var1 > Var2 Then { if NextBarOpen > C Then Buy("b",AtStop,NextBarOpen+PriceScale*-20); if NextBarOpen < C Then Buy("bx",AtStop,NextBarOpen-PriceScale*-20); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,5); Var2 = ma(C,1); if NextBarSdate != sDate and var1 > Var2 Then { if NextBarOpen > C Then Buy("b1",AtStop,NextBarOpen+PriceScale*-20); if NextBarOpen < C Then Buy("bx1",AtStop,NextBarOpen-PriceScale*-20); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,4); Var2 = ma(C,1); if NextBarSdate != sDate and var1 > Var2 Then { if NextBarOpen > C Then Buy("b2",AtStop,NextBarOpen+PriceScale*-20); if NextBarOpen < C Then Buy("bx2",AtStop,NextBarOpen-PriceScale*-20); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,1); Var2 = ma(C,5); if NextBarSdate != sDate and var1 > Var2 Then { if NextBarOpen > C Then Buy("b3",AtStop,NextBarOpen+PriceScale*-20); if NextBarOpen < C Then Buy("bx3",AtStop,NextBarOpen-PriceScale*-20); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); --------------- 위 수식어에 60선 아래 진입신호금지를 추가 부탁드립니다. ------------------------------------------------------------------- input : 익절틱수(120),손절틱수(30); var1 = ma(C,1); Var2 = ma(C,5); if NextBarSdate != sDate and var1 < Var2 Then { if NextBarOpen > C Then Sell("s",AtStop,NextBarOpen+PriceScale*-18); if NextBarOpen < C Then Sell("sx",AtStop,NextBarOpen-PriceScale*-18); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,3); Var2 = ma(C,7); if NextBarSdate != sDate and var1 < Var2 Then { if NextBarOpen > C Then Sell("s1",AtStop,NextBarOpen+PriceScale*-18); if NextBarOpen < C Then Sell("sx1",AtStop,NextBarOpen-PriceScale*-18); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,5); Var2 = ma(C,10); if NextBarSdate != sDate and var1 < Var2 Then { if NextBarOpen > C Then Sell("s2",AtStop,NextBarOpen+PriceScale*-18); if NextBarOpen < C Then Sell("sx2",AtStop,NextBarOpen-PriceScale*-18); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); var1 = ma(C,7); Var2 = ma(C,1); if NextBarSdate != sDate and var1 < Var2 Then { if NextBarOpen > C Then Sell("s3",AtStop,NextBarOpen+PriceScale*-18); if NextBarOpen < C Then Sell("sx3",AtStop,NextBarOpen-PriceScale*-18); } SetStopProfittarget(PriceScale*익절틱수,PointStop); SetStopLoss(PriceScale*손절틱수,PointStop); --------------------- 위 수식어에 60선 위 진입신호금지를 추가 부탁드립니다.
프로필 이미지
푸른
2022-09-07
977
글번호 162049
시스템
답변완료

변수배치, 에러

안녕세요~ -Inputs 과 Vars를 문장 최상단에 배치하지 않고 변수 사용문장 상단에 각각 배치해도 되는지요?? 예시> Inputs Vars 문장1 Inputs Vars 문장2 Inputs Vars 문장3
프로필 이미지
코퍼
2022-09-07
974
글번호 162048
시스템