커뮤니티
예스랭귀지 Q&A
답변완료
[공지] 예스랭귀지 AI 어시스턴트, '예스나 AI' 출시 및 무료 체험 안내
안녕하세요, 예스스탁 입니다.복잡한 수식 공부 없이 여러분의 아이디어를 말하면 시스템 트레이딩 언어 예스랭귀지로 작성해주는 서비스예스나 AI(YesNa AI)가 출시되었습니다.지금 예스나 AI를 직접 경험해 보실 수 있도록 20크레딧(질문권 20회)를 무료로 증정해 드리고 있습니다.바로 여러분의 아이디어를 코드로 변환해보세요.--------------------------------------------------🚀 YesNa AI 핵심 기능- 지표식/전략식/종목검색식 생성: 자연어로 요청하면 예스랭귀지 문법에 맞는 코드를 작성합니다.- 종목검색식 변환 지원: K증권의 종목 검색식을 예스랭귀지로 변환 지원합니다.- 컴파일 검증: 작성된 코드가 실행 가능한지 컴파일러를 통해 문법 검증을 거쳐 결과물을 제공합니다.상세한 서비스 개요 및 활용 방법은 [서비스 소개 페이지]에서 확인하실 수 있습니다.▶ 서비스 소개 페이지: 바로가기서비스 사용 유의사항 및 결제 환불정책은 [이용약관]을 참고 부탁드립니다.▶ 서비스 이용약관: 바로가기💬 이용 문의사용 중 문의사항은 [프로그램 사용법 Q&A] 게시판에서 [예스나 AI] 카테고리를 설정 후 문의해 주시면 상세히 안내해 드리겠습니다.--------------------------------------------------앞으로도 AI를 활용한 다양한 트레이딩 기능들을 지속적으로 선보일 예정입니다.많은 관심과 기대 부탁드립니다.
2026-02-27
3578
글번호 230811
답변완료
수정 부탁드립니다.
안녕하세요?
아래의 수식에서 두가지 수정을 하고싶습니다.
1. 이평선 삭제
2. 재진입 부분수정 (재진입은 1회만하고, 손/익절 이후 정상매매)
--> 정상진입후, 손/익절 범위내에서 반대신호가나면 1회만 재진입.
(매수 포지션보유시 매도신호에만 재진입, 또는 매도 포지션보유시 매수신호에만 재진입)
부탁드립니다.
감사합니다.
input : P1(5),P2(20),n(1);
input : 익절틱수(50),손절틱수(50);
var1 = ma(C,P1);
Var2 = ma(C,P2);
var3 = abs(C-O);
if MarketPosition == 0 and
countif(var1 > Var2 and C < O,3) == 3 and
Var3 == Var3[2] Then
Sell("s");
if MarketPosition == 0 and
countif(var1 > Var2 and C > O,3) == 3 and
Var3 == Var3[2] Then
Buy("b");
if MarketPosition == -1 and IsEntryName("s") == true and BarsSinceEntry <= n and C > O Then
Buy("sb");
if MarketPosition == 1 and IsEntryName("b") == true and BarsSinceEntry <= n and C < O Then
Sell("bs");
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
2020-12-07
582
글번호 144472
답변완료
추가라인 부탁드립니다.
안녕하세요...글번호 69990 에 30분봉에 고점.저점 라인 부탁드립니다.
plotno 65 30분봉에 고점라인
plotno 66 30분봉에 저점라인
(예) 9시~ 9/30분 고점.저점.
9/30~ 10/00 고점.저점
10/00~ 10/30 고점.저점
이런식으로 장종료까지그려지게요.
수고하세요....꾸벅
2020-12-07
574
글번호 144468
2wnwn 님에 의해서 삭제되었습니다.
2020-12-07
11
글번호 144467
답변완료
문의드립니다.
input : price(278.0);
if MarketPosition == 0 and H < Price Then
Buy("b",AtStop,Price);
ExitLong("Bp",AtLimit,Price+PriceScale*20);
ExitLong("Bl",AtStop,Price-PriceScale*5);
위에 로직은 매수 진입의 경우인데요.
이번에는 반대로 매도의 경우
기준가를 설정하고 주가가 기준가 돌파시 매도진입
기준가에서 5틱 상승시 손절매도
기준가에서 20틱 하락시 청산완료
국내선물에서
기준선을 278.00으로한다고 가정하고 부탁드립니다.
2020-12-07
629
글번호 144466
답변완료
excel 함수의 YL 화( Loginv)
예스스탁 덕에 많은 발전을 하고 있어,
항상 감사드리는 마음으로 질문을 하나 올립니다.
https://support.microsoft.com/ko-kr/office/loginv-%ED%95%A8%EC%88%98-0bd7631a-2725-482b-afb4-de23df77acfe
로그 정규 누적 분포 함수의 역함수 값 을 구하려고 하는데,
특정표본집단에서 어떤 일이 일어날때, 신뢰구간(로그 정규 분포와 관련된 확률)에서 일어나는
값? 구할때 쓰는 것인데. (상기 링크의 함수 설명 참조)
YL의 함수로 표현하고자 하는데 가능할까요?
2020-12-06
745
글번호 144465
답변완료
수식작성 부탁드립니다
안녕하세요,
value1= h/2;
value2= c/4;
value3= (value1+value2)/2;
value4= valuewhen(1, time==150000,value3(0))
키움증권 수식으로 위 공식을 만들었는데 예스트레이더 함수식으로 변환 가능한지요?
2020-12-06
723
글번호 144464
답변완료
질문드립니다.
if t <= 0 and condition1==true Then
{
t = 1;
value1= a;
}
if t >= 0 and condition2==true Then
{
t = -1;
value1= b;
}
위와 같은 식에 의해 다음과 같이 빨간선과 파란선이 그려져왔다고 칠 때
빨강1구간-파랑1구간-빨강2구간-파랑2구간-빨강3구간-파랑3구간...
현재 구간이 파랑3구간이라면 현 위치에서 파랑2구간의 시작봉의 시가, 그리고 파랑2구간 영역전체 전개되는 캔들에 대한 최고점과 최저점을 현 위치에서 파악할 있는 수식을 부탁드립니다. 즉, 파랑3구간이 끝나고 빨강4구간이 시작된다면 빨강3구간에 대한 시가, 그리고 빨강3구간 영역전체에 전개되는 캔들의 최고점과 최저점.. 이런 방식입니다. 즉, 현재구간에서
전전구간의 정보를 알수있는 수식을 부탁드립니다.
2020-12-07
646
글번호 144463
하운드독 님에 의해서 삭제되었습니다.
2020-12-06
6
글번호 144462
답변완료
TS OHLCPeriodsAgo (Function) 의 YES 변환 문의
수고하십니다.
TS의 함수중 지정 주기의 시고저종가를 반환하는 함수입니다.
YES 초보라서 좀 어렵네요.
YES 랭귀지 함수로 변환을 부탁드립니다.
감사합니다.
inputs:
PeriodType( numericsimple ),
PeriodsAgo( numericsimple ),
oPeriodOpen( numericref ),
oPeriodHigh( numericref ),
oPeriodLow( numericref ),
oPeriodClose( numericref ) ;
variables:
var0( 0 ), sess_last_bar(false) ;
arrays:
arr0[ 4, 50 ]( -1 ) ;
sess_last_bar = sessionlastbar;
condition1 = PeriodsAgo > 50 or BarType > IFF(PeriodType<>0, PeriodType + 1, PeriodType + 2) or BarType > 4 ;
if condition1 then
begin
oPeriodOpen = -1 ;
oPeriodHigh = -1 ;
oPeriodLow = -1 ;
oPeriodClose = -1 ;
OHLCPeriodsAgo = -1 ;
end
else
begin
if PeriodType = 0 then
Condition1 = sess_last_bar[1]
else if PeriodType = 1 then
Condition1 = Date <> Date[1]
else if PeriodType = 2 then
Condition1 = DayOfWeek( Date ) < DayOfWeek( Date[1] )
else if PeriodType = 3 then
Condition1 = Month( Date ) <> Month( Date[1] )
else if PeriodType = 4 then
Condition1 = Year( Date ) <> Year( Date[1] ) ;
condition1 = CurrentBar = 1 or Condition1 ;
if condition1 then
begin
var0 = var0 - 1 ;
if var0 = -1
then var0 = 50 ;
arr0[ 1, var0 ] = O ;
arr0[ 2, var0 ] = H ;
arr0[ 3, var0 ] = L ;
arr0[ 4, var0 ] = C ;
end
else
begin
condition1 = H > arr0[ 2, var0 ] ;
if condition1 then arr0[ 2, var0 ] = H ;
condition1 = L < arr0[ 3, var0 ] ;
if condition1 then arr0[ 3, var0 ] = L ;
arr0[ 4, var0 ] = C ;
end ;
oPeriodOpen = arr0[ 1, Mod( var0 + PeriodsAgo, 51 ) ] ;
oPeriodHigh = arr0[ 2, Mod( var0 + PeriodsAgo, 51 ) ] ;
oPeriodLow = arr0[ 3, Mod( var0 + PeriodsAgo, 51 ) ] ;
oPeriodClose = arr0[ 4, Mod( var0 + PeriodsAgo, 51 ) ] ;
OHLCPeriodsAgo = 1 ;
end ;
if false then
Value1 = OHLCPeriodsAgo[1] ;
--------------------------------------------------------------------------
아래는 함수 설명입니다.
OHLCPeriodsAgo (Function)
image₩trumpet2.gif Disclaimer
The OHLCPeriodsAgo series function returns the Open, High, Low, and Close of a specified time segment, a specified number of periods ago.
Syntax
OHLCPeriodsAgo(PeriodType, PeriodsAgo, oPeriodOpen, oPeriodHigh, oPeriodLow, oPeriodClose)
Returns (Integer)
The oPeriodOpen, oPeriodHigh, oPeriodLow, and oPeriodCLose output parameters returns the Open, High, Low, and Close from a time segment. The OHLCPeriodsAgo function itself returns 1 if the specified time segment was available, and -1 if not.
Parameters
Name
Type
Description
PeriodType
Numeric
Sets the time period on which to base values (1=Day, 2=Week, 3=Month, 4=Year)
PeriodsAgo
Numeric
Sets the number of PeriodType periods ago
oPeriodOpen
Numeric
Outputs the open of the specified time segment
oPeriodHigh
Numeric
Outputs the high of the specified time segment
oPeriodLow
Numeric
Outputs the low of the specified time segment
oPeriodClose
Numeric
Outputs the close of the specified time segment
Remarks
See Multiple Output Function for more information on using output parameters to return values.
Example
Assigns to Value2 through Value5 the Open, High, Low, and Close of the last 20 weeks. Value1 is assigned a value of 1.
vars: oPeriodOpen(0), oPeriodHigh(0), oPeriodLow(0), oPeriodClose(0);
Value1 = OHLCPeriodsAgo(2, 20, oPeriodOpen, oPeriodHigh, oPeriodLow, oPeriodClose);
Value2 = oPeriodOpen;
Value3 = oPeriodHigh;
Value4 = oPeriodLow;
Value5 = oPeriodClose;
2020-12-06
982
글번호 144461