커뮤니티

예스랭귀지 Q&A

글쓰기
답변완료

수정 부탁드립니다.

안녕하세요? 아래의 수식에서 두가지 수정을 하고싶습니다. 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
556
글번호 144472
시스템
답변완료

추가라인 부탁드립니다.

안녕하세요...글번호 69990 에 30분봉에 고점.저점 라인 부탁드립니다. plotno 65 30분봉에 고점라인 plotno 66 30분봉에 저점라인 (예) 9시~ 9/30분 고점.저점. 9/30~ 10/00 고점.저점 10/00~ 10/30 고점.저점 이런식으로 장종료까지그려지게요. 수고하세요....꾸벅
프로필 이미지
보인다
2020-12-07
553
글번호 144468
지표

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

프로필 이미지
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
608
글번호 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
647
글번호 144465
사용자 함수
답변완료

수식작성 부탁드립니다

안녕하세요, value1= h/2; value2= c/4; value3= (value1+value2)/2; value4= valuewhen(1, time==150000,value3(0)) 키움증권 수식으로 위 공식을 만들었는데 예스트레이더 함수식으로 변환 가능한지요?
프로필 이미지
므니엘
2020-12-06
701
글번호 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
619
글번호 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;
프로필 이미지
sky93
2020-12-06
836
글번호 144461
사용자 함수
답변완료

개별요인에 의한 순 수익률 작성

타종목 참조를 활용하여, 개별종목의 순수익률을 반영한 종가를 작성하고 싶습니다. EXCEL로는 표현을 할수 있겠는데, YL은 자기참조 표현을 잘못하겠네요. 첨부 excel의 G 행의 값처럼 표현하고 싶습니다 (첨부참조) 주종목(DATA1)에는 개별종목 (EX.삼성전자) 타종목(DATA2)에는 타종목 (EX. KOSPI 지수) 표현하고자하는 지표 : 주종목차트의 최초의 종가를 시작으로 하기 '개별순수익률'을 반영한, 주종목의 종가(CLOSE) //======작성수식==== Input:base(1.5),Length(60), 차트상의첫종가(100); Var:x(0),y(0),Beta(0),Alpha(0) , 개별순수익률 (0) ; y = (C - C[1])*100/C[1]; //종목변동률 x = (data2(C) - data2(C[1]))*100/data2(C[1]); //시장변동률, data2는 코스피 또는 코스닥 지수 Beta = (ma(x*y, length) - ma(x,length) * ma(y,length)) / (ma(x^2,length) - (ma(x,length)^2)); Alpha = ma(y,length) - (ma(x*y, length) - ma(x,length) * ma(y,length)) / (ma(x^2,length) - (ma(x,length)^2)) * ma(x,length); PLOTBASELINE1 (0,"0"); Plot1(Beta,"베타",iff(Beta>base,RED,BLUE)); Plot2(Alpha,"알파",iff(Alpha>base,RED,BLUE)); /*===========개별요인에 의한 순 수익률 * 종목의 주가 변화 = 종합지수 변화 + 종목의 개별요인 ---- (식-1) 종목의 개별요인 = 종목의 주가 변화 - 종합지수 변화 개별요인에 의한 순 수익률 = 주가의 수익률 - 베타 * 종합지수의 수익률 ---- (식-2) */ 개별순수익률 = (Y -Beta* X)*0.01; // <=식-2 개별순수익주가 = ; //???? <=표현하고자하는 지표. //------------------
프로필 이미지
하운드독
2020-12-06
802
글번호 144460
지표