커뮤니티

예스랭귀지 Q&A

글쓰기

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

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

부탁드립니다

수고하십니다아래수식을 오류 없게 수정부탁드립니다Inputs: Period(200), VPResolution(50), ShowPoC(true), ShowPivots(true), PivotLength(10), PivotFilter(20);Variables: i(0), j(0), k(0), HighestPrice(0), LowestPrice(0), BinSize(0), BinLow(0), BinHigh(0), BinMid(0), BinValue(0), MaxBinValue(0), VolPercent(0), Left(0), Right(0), PocPrice(0), PocVolume(0), TotalDelta(0), CurrentDelta(0), // Pivot 관련 PH(0), PL(0), PivotPrice(0), PivotBar(0), PivotIndex(0), // Drawing Objects TLRef(0), TextRef(0), RectRef(0), // 색상 ProfileColor(0), BarColor(0);Arrays: VolumeBins[100](0), DeltaBins[100](0), PivotPrices[500](0), PivotBars[500](0), PivotTypes[500](0), // 1 = High, -1 = Low PivotProcessed[500](0), // 0 = not processed, 1 = processed VPTrendLines[100](0), VPLabels[100](0);// 이전 Drawing Objects 삭제 (마지막 바에서만)if Date <> Date[1] or Time <> Time[1] then begin for i = 0 to VPResolution - 1 begin if VPTrendLines[i] > 0 then begin TL_Delete(VPTrendLines[i]); VPTrendLines[i] = 0; end; if VPLabels[i] > 0 then begin Text_Delete(VPLabels[i]); VPLabels[i] = 0; end; end;end;// Pivot High 감지PH = 0;if CurrentBar > PivotLength * 2 then begin if High[PivotLength] == Highest(High, 2 * PivotLength + 1) then PH = High[PivotLength];end;// Pivot Low 감지PL = 0;if CurrentBar > PivotLength * 2 then begin if Low[PivotLength] == Lowest(Low, 2 * PivotLength + 1) then PL = Low[PivotLength];end;// Pivot 저장 및 처리if PH > 0 then begin PivotIndex = -1; // 빈 슬롯 찾기 for i = 0 to 499 begin if PivotBars[i] = 0 then begin PivotIndex = i; break; end; end; if PivotIndex >= 0 then begin PivotPrices[PivotIndex] = PH; PivotBars[PivotIndex] = CurrentBar - PivotLength; PivotTypes[PivotIndex] = 1; // High PivotProcessed[PivotIndex] = 0; end;end;if PL > 0 then begin PivotIndex = -1; // 빈 슬롯 찾기 for i = 0 to 499 begin if PivotBars[i] = 0 then begin PivotIndex = i; break; end; end; if PivotIndex >= 0 then begin PivotPrices[PivotIndex] = PL; PivotBars[PivotIndex] = CurrentBar - PivotLength; PivotTypes[PivotIndex] = -1; // Low PivotProcessed[PivotIndex] = 0; end;end;// Volume Profile 계산 및 시각화if CurrentBar >= Period then begin // 범위 계산 HighestPrice = Highest(High, Period); LowestPrice = Lowest(Low, Period); if HighestPrice > LowestPrice then begin BinSize = (HighestPrice - LowestPrice) / VPResolution; // Bins 초기화 for i = 0 to VPResolution - 1 begin VolumeBins[i] = 0; DeltaBins[i] = 0; end; // Volume 데이터 수집 for j = 0 to Period - 1 begin for i = 0 to VPResolution - 1 begin BinLow = LowestPrice + BinSize * i; BinHigh = BinLow + BinSize; if Close[j] >= BinLow - BinSize and Close[j] < BinHigh + BinSize then begin VolumeBins[i] = VolumeBins[i] + Volume[j]; // Delta 계산 if Close[j] > Open[j] then DeltaBins[i] = DeltaBins[i] + Volume[j]; else DeltaBins[i] = DeltaBins[i] - Volume[j]; end; end; end; // 최대 Volume 찾기 MaxBinValue = 0; for i = 0 to VPResolution - 1 begin if VolumeBins[i] > MaxBinValue then MaxBinValue = VolumeBins[i]; end; // PoC 및 Total Delta 계산 PocVolume = 0; PocPrice = 0; TotalDelta = 0; for i = 0 to VPResolution - 1 begin TotalDelta = TotalDelta + DeltaBins[i]; if VolumeBins[i] > PocVolume then begin PocVolume = VolumeBins[i]; BinLow = LowestPrice + BinSize * i; BinHigh = BinLow + BinSize; PocPrice = (BinLow + BinHigh) / 2; end; end; // 색상 결정 (Delta 기반) if TotalDelta > 0 then ProfileColor = Cyan; else ProfileColor = Red; // Volume Profile 히스토그램 그리기 (마지막 바에서만) if LastBarOnChart then begin Left = CurrentBar - Period; for i = 0 to VPResolution - 1 begin BinLow = LowestPrice + BinSize * i; BinHigh = BinLow + BinSize; BinMid = (BinLow + BinHigh) / 2; BinValue = VolumeBins[i]; if MaxBinValue > 0 then begin VolPercent = (BinValue / MaxBinValue) * 100; Right = Left + Round((BinValue / MaxBinValue) * 50); // Delta 기반 색상 if DeltaBins[i] > 0 then BarColor = Cyan else BarColor = Red; // Volume Profile 바 그리기 (TrendLine 사용) if VPTrendLines[i] > 0 then TL_Delete(VPTrendLines[i]); VPTrendLines[i] = TL_New(Date[Period], Time[Period], BinMid, Date[Period - Right + Left], Time[Period - Right + Left], BinMid); TL_SetColor(VPTrendLines[i], BarColor); TL_SetSize(VPTrendLines[i], 4); // Pivot과 Volume Profile 교차점 표시 if ShowPivots then begin for k = 0 to 499 begin if PivotBars[k] > 0 and PivotProcessed[k] = 0 then begin PivotPrice = PivotPrices[k]; PivotBar = PivotBars[k]; // Pivot이 Volume Profile 범위 내에 있고 필터 조건 만족 if AbsValue(BinMid - PivotPrice) <= BinSize and VolPercent >= PivotFilter and CurrentBar - Period <= PivotBar then begin // Pivot 라인 그리기 if PivotTypes[k] = 1 then begin // Pivot High TLRef = TL_New(Date[CurrentBar - PivotBar + PivotLength], Time[CurrentBar - PivotBar + PivotLength], PivotPrice, Date[CurrentBar - PivotBar - PivotLength], Time[CurrentBar - PivotBar - PivotLength], PivotPrice); TL_SetColor(TLRef, DarkRed); TL_SetSize(TLRef, 2); // 라벨 추가 TextRef = Text_New(Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice, NumToStr(BinValue, 0) + " (" + NumToStr(VolPercent, 0) + "%)"); Text_SetColor(TextRef, DarkRed); Text_SetLocation(TextRef, Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice + BinSize); // 연장선 그리기 (Dotted) TLRef = TL_New(Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice, Date, Time, PivotPrice); TL_SetColor(TLRef, DarkRed); TL_SetStyle(TLRef, Tool_Dotted); TL_SetExtRight(TLRef, True); end else begin // Pivot Low TLRef = TL_New(Date[CurrentBar - PivotBar + PivotLength], Time[CurrentBar - PivotBar + PivotLength], PivotPrice, Date[CurrentBar - PivotBar - PivotLength], Time[CurrentBar - PivotBar - PivotLength], PivotPrice); TL_SetColor(TLRef, DarkGreen); TL_SetSize(TLRef, 2); // 라벨 추가 TextRef = Text_New(Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice, NumToStr(VolPercent, 0) + "% (" + NumToStr(BinValue, 0) + ")"); Text_SetColor(TextRef, DarkGreen); Text_SetLocation(TextRef, Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice - BinSize); // 연장선 그리기 (Dotted) TLRef = TL_New(Date[CurrentBar - PivotBar], Time[CurrentBar - PivotBar], PivotPrice, Date, Time, PivotPrice); TL_SetColor(TLRef, DarkGreen); TL_SetStyle(TLRef, Tool_Dotted); TL_SetExtRight(TLRef, True); end; PivotProcessed[k] = 1; end; end; end; end; end; end; end; end;end;// 오래된 Pivot 제거for i = 0 to 499 begin if PivotBars[i] > 0 and CurrentBar - PivotBars[i] > Period then begin PivotBars[i] = 0; PivotPrices[i] = 0; PivotTypes[i] = 0; PivotProcessed[i] = 0; end;end;// PoC 레벨 표시if ShowPoC and PocPrice > 0 then begin Plot1(PocPrice, "PoC Level", ProfileColor, Default, 2); // PoC 라벨 (마지막 바에서만) if LastBarOnChart then begin TextRef = Text_New(Date, Time, PocPrice, "POC: " + NumToStr(PocVolume, 0)); Text_SetColor(TextRef, ProfileColor); Text_SetLocation(TextRef, Date, Time, PocPrice); end;end;
프로필 이미지
파생돌이
2025-10-28
284
글번호 227383
지표
답변완료

수식 요청드립니다.

안녕하세요.매수진입 수식 1개로 피라미딩 진입하여 최대 5개까지 누적 매수 한다고 했을 시첫번째 매수진입 이후에는 첫번째 매수진입 시점부터 10분이상 경과 + 매수진입 조건 달성시 두번째 매수진입두번째 매수진입 시점부터 10분이상 경과 + 매수진입 조건 달성시 세번째 매수진입세번째 매수진입 시점부터 10분이상 경과 + 매수진입 조건 달성시 네번째 매수진입네번째 매수진입 시점부터 10분이상 경과 + 매수진입 조건 달성시 다섯번째 매수진입할수 있도록 하는 수식을 부탁드립니다. 감사합니다.
프로필 이미지
트레이더365
2025-10-28
145
글번호 227382
시스템

파생돌이 님에 의해서 삭제되었습니다.

프로필 이미지
파생돌이
2025-10-27
10
글번호 227381
지표
답변완료

종목검색 수식완성 부탁드립니다.

안녕하세요. 종목검색 수식 부탁드립니다.◆조건 1. 금일 첫 30분봉에서 ADX(10) > 25 이고, CrossUp(DI⁺, ADX) ◆조건 2. Chaikin Oscillator (3,10) 금일 첫 30분봉의 CO 값이 전일 마지막 30분봉 CO의 1.5배 이상 AND 금일 첫 30분봉 CO ≥ 0 ◆조건 3. 금일 첫 30분봉에서 RSI(14) 52 상향돌파 이상 세가지 조건을 만족하는 종목을 검색하는 수식을 부탁드립니다.감사합니다.
ADX RSI ChaikinOscillator
프로필 이미지
행복사랑채
2025-10-27
294
글번호 227378
종목검색
답변완료

부탁 드립니다.

Input : P(10); Var : LRLv(0); LRLv = LRL(C, P); Var1 = LRLv; Var2 = Var1[1];Plot1(var1); plot2(Var2); Print("C:\\WinnerData\\realtime_mymz25.csv", "%.f,%.f,%.f,%.1f,%.1f,%.f", Date, Time, Close, Var1, Var2, DayClose(1));위 수식에서 C:\WinnerData\realtime_mymz25.csv 의 출력에서 Date 의 출력 형식이 '2025-10-27 17:40:00 20251027' 와 같이 출력이 됩니다. Date 출력 형식에서 20251027(YYYYMMDD) 와 같이 년월일 만 출력이 되도록 수식을 변경 하여 주시면 감사하겠습니다.C:\WinnerData\realtime_mymz25.csv 출력내용2025-10-27 17:40:00 20251027 173204 47654 47767 .1 47768.8 47387Date : 2025-10-27-27 17:40:00 20251027 -------> 여기서 20251027 만 출력 되게 해 주십시요. (2025-10-27 17:40:00 이 부분이 없어야 합니다)아래의 항목들은 정상적으로 출력 됩니다.Time : 173204 Close : 47654var1 : 47767.1 var2 : 47768.8 DayClose(1) : 47387
Print csv
프로필 이미지
너무조아
2025-10-27
204
글번호 227371
지표
답변완료

종목검색 문의 드립니다

오늘 하루중 5분봉상 RSI가 70이상 올라갔던 종목을 장끝나고 찾아볼수 있는 검색식 어떻게 될까요?
RSI
프로필 이미지
비리번
2025-10-27
149
글번호 227369
종목검색
답변완료

부탁드립니다

1,A= Disparity(Period); D=ValueWhen(1, crossup(A, 기준) OR crossdown(A, 기준) ,가격)지표조건 period 120 기준 101 가격 (H+L)/2D지표값이 10%이상하락 했다 N일전에 하락하고 오늘 까지 하락한 지표값이 유지중인 종목 검색식 부탁 드립니다 N일은 5일 7일 10일 등등 입니다2,A1=Highest(V,기간1);B1=Valuewhen(1,V>A1(1),(O+C+L+H+C)/5);지표조건기간1 60B1지표값이 10%이상하락 했다 N일전에 하락하고 오늘 까지 하락한 지표값이 유지중인 종목 검색식 부탁 드립니다 N일은 5일 7일 10일 등등 입니다
프로필 이미지
님이랑
2025-10-27
170
글번호 227346
종목검색
답변완료

Data2(지수C)

data2()로 종합주가지수 최근 종가 다른 지표에서 참조하여 그 지표에 화면출력하는 코드부탁합니다.
프로필 이미지
dedoyes
2025-10-27
140
글번호 227342
지표
답변완료

문의드립니다

안녕하세요? 아래수식에 에러가있습니다 그리고신호가발생했으면 합니다 감사합니다Inputs: TL11(0), TL21(0), CrossTolerance(10), ContractCount(1);Vars: valTL1_now(0), valTL2_now(0), valTL1_prev(0), valTL2_prev(0), diff(0), LastCrossBar(0), CrossLine(0);//---------------------------------------------// 추세선 존재 시에만 작동//---------------------------------------------If (TL11 > 0) and (TL21 > 0) ThenBegin // 현재 봉 값 valTL1_now = TL_GetValue(TL11, Date, Time); valTL2_now = TL_GetValue(TL21, Date, Time); // 이전 봉 값 valTL1_prev = TL_GetValue(TL11, Date[1], Time[1]); valTL2_prev = TL_GetValue(TL21, Date[1], Time[1]); diff = AbsValue(valTL1_now - valTL2_now); // 교차 근접 표시 If diff <= (PriceScale * CrossTolerance) Then Begin If LastCrossBar <> CurrentBar Then Begin CrossLine = TL_New(Date[1], Time[1], Close[1], Date, Time, Close); TL_SetColor(CrossLine, Yellow); TL_SetSize(CrossLine, 1); LastCrossBar = CurrentBar; End; End; // 교차 감지 → 1봉 뒤 자동매매 If (valTL1_prev < valTL2_prev) and (valTL1_now > valTL2_now) Then Buy ContractCount contracts next bar at market Else If (valTL1_prev > valTL2_prev) and (valTL1_now < valTL2_now) Then Sell ContractCount contracts next bar at market;End;
프로필 이미지
새벽에
2025-10-27
127
글번호 227339
시스템