커뮤니티
예스랭귀지 Q&A
답변완료
[공지] 예스랭귀지 AI 어시스턴트, '예스나 AI' 출시 및 무료 체험 안내
안녕하세요, 예스스탁 입니다.복잡한 수식 공부 없이 여러분의 아이디어를 말하면 시스템 트레이딩 언어 예스랭귀지로 작성해주는 서비스예스나 AI(YesNa AI)가 출시되었습니다.지금 예스나 AI를 직접 경험해 보실 수 있도록 20크레딧(질문권 20회)를 무료로 증정해 드리고 있습니다.바로 여러분의 아이디어를 코드로 변환해보세요.--------------------------------------------------🚀 YesNa AI 핵심 기능- 지표식/전략식/종목검색식 생성: 자연어로 요청하면 예스랭귀지 문법에 맞는 코드를 작성합니다.- 종목검색식 변환 지원: K증권의 종목 검색식을 예스랭귀지로 변환 지원합니다.- 컴파일 검증: 작성된 코드가 실행 가능한지 컴파일러를 통해 문법 검증을 거쳐 결과물을 제공합니다.상세한 서비스 개요 및 활용 방법은 [서비스 소개 페이지]에서 확인하실 수 있습니다.▶ 서비스 소개 페이지: 바로가기서비스 사용 유의사항 및 결제 환불정책은 [이용약관]을 참고 부탁드립니다.▶ 서비스 이용약관: 바로가기💬 이용 문의사용 중 문의사항은 [프로그램 사용법 Q&A] 게시판에서 [예스나 AI] 카테고리를 설정 후 문의해 주시면 상세히 안내해 드리겠습니다.--------------------------------------------------앞으로도 AI를 활용한 다양한 트레이딩 기능들을 지속적으로 선보일 예정입니다.많은 관심과 기대 부탁드립니다.
2026-02-27
4437
글번호 230811
하늘거지 님에 의해서 삭제되었습니다.
2018-09-21
8
글번호 122220
답변완료
문의드립니다.
도움주시는 덕분에 도전하고 있습니다. 매번 감사합니다. 즐거운 명절 되세요.
1. 기타
59300 수식(추가답변에 달린 추가진입하는 버전으로) sell도 가능하게 수정 부탁드립니다.
2. 기타
59300수식을 선물에다가도 적용가능한가요?
3.
예스로 수정부탁드립니다.
// Indicator: Fisherized Deviation Scaled Oscillator
inputs:
Period( 40 ),
OverBought( 2 ),
OverSold( -2 ),
OutPutData( false ),
FilePath( "C:ProbabilityDensity.CSV" ) ;
variables:
a1( 0 ), b1( 0 ), c1( 0 ), c2( 0 ),
c3( 0 ), Zeros( 0 ), Filt( 0 ), RMS( 0 ),
count( 0 ), ScaledFilt( 0 ), FisherFilt( 0 ),
Idx( 0 ), J( 0 ), K( 0 ) ;
arrays:
Bin[61](0);
if CurrentBar = 1 Then
//once
begin
//Smooth with a Super Smoother
a1 = expvalue( -1.414 * 3.14159 / ( .5 * Period ) ) ;
b1 = 2 * a1 * Cosine( 1.414 * 180 / ( .5 * Period ) ) ;
c2 = b1 ;
c3 = -a1 * a1 ;
c1 = 1 - c2 - c3 ;
end ;
//Produce Nominal zero mean with zeros in the transfer response
at
//DC and Nyquist with no spectral distortion
//Nominally whitens the spectrum because of 6 dB per octave
rolloff
Zeros = Close - Close[2] ;
//SuperSmoother Filter
Filt = c1 * ( Zeros + Zeros[1] )
/ 2 + c2 * Filt[1] + c3 * Filt[2] ;
//Compute Standard Deviation
RMS = 0;
For count = 0 to Period - 1
begin
RMS = RMS + Filt[count] * Filt[count] ;
end;
RMS = SquareRoot( RMS / Period ) ;
//Rescale Filt in terms of Standard Deviations
If RMS <> 0 then
ScaledFilt = Filt / RMS ;
//Apply Fisher Transform to establish real Gaussian Probability
//Distribution
If AbsValue( ScaledFilt ) < 2 then
FisherFilt = .5 *
Log( ( 1 + ScaledFilt / 2 ) / ( 1 - ScaledFilt / 2 ) ) ;
Plot1( FisherFilt, "Fisher Filt" ) ;
Plot2( 0, "ZL" ) ;
Plot3( OverBought, "OB" ) ;
Plot4( OverSold, "OS" ) ;
//Bin the indicator values in Bins from -3 to +3
if OutPutData then
begin
For Idx = 1 to 60
begin
J = (Idx - 31) / 10;
K = (Idx - 30) / 10;
If FisherFilt > J and FisherFilt <= K then
Bin[Idx] = Bin[Idx] + 1;
end;
//Output the Bin measurements to a file
once ( LastBarOnChartEx )
begin
FileDelete( FilePath ) ;
For Idx = 1 to 61
begin
FileAppend( FilePath, NumToStr( .1 * ( Idx - 31 ), 1 )
+ "," + NumToStr( Bin[Idx], 0 ) + NewLine ) ;
end;
end ;
end ;
Strategy: Fisherized Deviation Scaled Oscillator
// TASC OCT 2018
// Ehlers FDSA
inputs:
Period( 40 ),
OverBought( 2 ),
OverSold( -2 ),
OutPutData( false ),
FilePath( "C:DataProbabilityDensity.CSV" ) ;
variables:
a1( 0 ), b1( 0 ), c1( 0 ), c2( 0 ),
c3( 0 ), Zeros( 0 ), Filt( 0 ), RMS( 0 ),
count( 0 ), ScaledFilt( 0 ), FisherFilt( 0 ),
Idx( 0 ), J( 0 ), K( 0 ) ;
arrays:
Bin[61](0);
if CurrentBar = 1 Then
//once
begin
//Smooth with a Super Smoother
a1 = expvalue( -1.414 * 3.14159 / ( .5 * Period ) ) ;
b1 = 2 * a1 * Cosine( 1.414 * 180 / ( .5 * Period ) ) ;
c2 = b1 ;
c3 = -a1 * a1 ;
c1 = 1 - c2 - c3 ;
end ;
//Produce Nominal zero mean with zeros in the transfer response
at
//DC and Nyquist with no spectral distortion
//Nominally whitens the spectrum because of 6 dB per octave
rolloff
Zeros = Close - Close[2] ;
//SuperSmoother Filter
Filt = c1 * ( Zeros + Zeros[1] )
/ 2 + c2 * Filt[1] + c3 * Filt[2] ;
//Compute Standard Deviation
RMS = 0;
For count = 0 to Period - 1
begin
RMS = RMS + Filt[count] * Filt[count] ;
end;
RMS = SquareRoot( RMS / Period ) ;
//Rescale Filt in terms of Standard Deviations
If RMS <> 0 then
ScaledFilt = Filt / RMS ;
//Apply Fisher Transform to establish real Gaussian Probability
//Distribution
If AbsValue( ScaledFilt ) < 2 then
FisherFilt = .5 *
Log( ( 1 + ScaledFilt / 2 ) / ( 1 - ScaledFilt / 2 ) ) ;
if FisherFilt crosses below OverBought then
Sell Short next bar at Market
else if FisherFilt crosses over OverSold then
Buy next bar at Market ;
if FisherFilt crosses below 0 then
Sell next bar at Market
else if FisherFilt crosses over 0 then
Buy to Cover next bar at Market ;
2018-09-21
306
글번호 122216
답변완료
기준선 수식 수정 부탁드립니다.
아래의 수식을 적용해 보았습니다.
첨부드리는 그림상에 검은색 선이 일목균형표 기준선을 26에서 120으로 수정한 선이구요.
챠트는 1분봉입니다.
그림상의 첫번째 화살표에서 매수진입
두번째 화살표에서 매수청산 및 매도진입
세번째 화살표(정확한 값은 아닙니다. 개념상의 위치이며 실제로 50틱이 되지는 않습니다.)에서 매도청산이 나와서 당일 매매가 종료되도록 만들어 볼려고 하였습니다.
현재 발생되는 시그널은 일목균형표 기준선과 전혀 다른 위치에서 발생됩니다. 그림상의 날짜에는 그래도 위치가 비슷하게라도 나오는데 다른 날짜에서 보면 완전히 다른 위치입니다.
어디가 문제인지 점검 좀 부탁드립니다.
- 아 래 -
Input : 당일누적수익틱수(50),당일누적손실틱수(50);
input : starttime(101500),endtime(020000);
VARS: Tcond(false),N1(0),dayPl(0),당일누적수익(0),당일누적손실(0),Xcond(false);
if (sdate != sdate[1] and stime >= endtime) or
(sdate == sdate[1] and stime >= endtime and stime[1] < endtime) then
{
Tcond = false;
if MarketPosition == 1 Then
ExitLong("bx");
if MarketPosition == -1 Then
ExitShort("sx");
}
if (sdate != sdate[1] and stime >= starttime) or
(sdate == sdate[1] and stime >= starttime and stime[1] < starttime) then
{
Xcond = false;
N1 = NetProfit;
Tcond = true;
}
당일누적수익 = PriceScale*당일누적수익틱수;
당일누적손실 = PriceScale*당일누적손실틱수;
daypl = NetProfit-N1;
if TotalTrades > TotalTrades[1] and
(IsExitName("dbp",1) == true or IsExitName("dbl",1) == true or
IsExitName("dsp",1) == true or IsExitName("dsl",1) == true) then
Xcond = true;
var1 = (highest(H,26)+lowest(L,26))/2;
if Tcond == true and Xcond == false then
{
if crossup(c,var1) Then
buy();
if CrossDown(c,var1) Then
sell();
}
if MarketPosition == 1 then{
ExitLong("dbp",atlimit,EntryPrice+((당일누적수익-daypl)/CurrentContracts));
ExitLong("dbl",AtStop,EntryPrice-((당일누적손실+daypl)/CurrentContracts));
}
if MarketPosition == -1 then{
ExitShort("dsp",atlimit,EntryPrice-((당일누적수익-daypl)/CurrentContracts));
ExitShort("dsl",AtStop,EntryPrice+((당일누적손실+daypl)/CurrentContracts));
}
2018-09-20
333
글번호 122212
답변완료
사진처럼 가능할까요?
일목인데요 위처럼 차트 만들고
빨간색 매수 파란색 매도 하는 거 가능할까요?
더불어 일목의 수치와 선행1,선행2 수평 수치도 변경가능하면 좋겠습니다~
감사합니다
2018-09-20
251
글번호 122211
답변완료
부탁합니다
종목검색식을 부탁합니다
바이너리웨이브(20,12,5,3)외부변수처리. -2 ~ 0까지 ( -2, 0포함)
바이너리웨이브(5,14,5,3)외부변수처리. 0 선 ~ 2까지 ( 0, 2포함)
스토캐스틱(12,5,5)외부변수처리, K > D.
스토캐스틱(26,17,4,5)외부변수처리, D > K
주석처리부탁합니다.
2018-09-20
166
글번호 122210
답변완료
함수식
안녕하세요
아침 9시 장이시작되면 아래의 로직을 돌려보았습니다
아래 함수식에서 청산조건 만족시 청산이 되지 않습니다
수정부탁드립니다 수고하세요
input : p1(5), P2(20),P3(60);
value1 = ma(c,P1);
value2 = ma(c,P2);
value3 = ma(c,P3);
if Value2 > Value3 then{ if CrossUp( Value1 , Value2) then{
buy();
if CrossDown( Value1 , Value3) then{
ExitShort();
}}}
if Value2 < Value3 then{ If CrossDown(Value1 , Value2) then{
sell();
If Crossup(Value1 , Value3) then{
ExitShort();
}}
}
2018-09-20
155
글번호 122209
답변완료
안녕하세요? 수식 여쭤봅니다.
input : mm(1000000);
if stime == 151800 and C <= DayLow(0)+(DayHigh(0)-DayLow(0))*0.2 Then
buy("b",OnClose,def,Floor(mm/c));
if NextBarSdate > sdate and C >= DayHigh(0)-(DayHigh(0)-DayLow(0))*0.2 Then
ExitLong("bx",AtMarket);
위의 식에
종목의
일봉 이동평균이 5>10>20>60(정배열) 일때에만 매수가 일어나는 조건을 추가 하고 싶습니다.
감사합니다.
2018-09-20
160
글번호 122208
답변완료
캔들
늘 수고가 많으십니다
혹시나 캔들 모양을 점으로 나타낼수 있는지요???
양봉은 빨간색
음봉은 파란색
가능할까요????????
가능하다면 고가 중가 저가로 선택할수 있게 부탁드립니다
양봉은 고가 음봉은 저가
음봉은 중가 양봉은 저가
이런식으로 선택 가능하게끔 부탁드려 봅니다~~
2018-09-20
188
글번호 122207
답변완료
시스템식 문의
1분봉에서 100선 올라서면 매수 내려서면 매도 하는 수식좀 부탁드립니다
봉의갯수는 2000선을 기본으로 하고요
2018-09-20
158
글번호 122201