커뮤니티

수정부탁합니다.

프로필 이미지
뉴스타트
2012-05-04 13:07:13
306
글번호 50784
답변완료
하이에서 사용중입니다. 24104 관련하여 답변주신것을 갭보정으로 수정해주세요. 수고하세요.
지표
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2012-05-04 14:40:57

안녕하세요 예스스탁입니다. GRCI이름으로 새로 작성해서 사용하시면 됩니다. 1. 사용자함수명 : GRCI 반환형값 : 숫자 input : Period(Numeric); Var : cnt(0),Nth(0),tempmax(0), tempindex(0), X1(0),RCI1(0); Array : VALUE1[50](0),NTHVALUE[50](0); var : sumGap(0), gap(0), GC(0); if date!=date[1] then { gap = Open-Close[1]; sumGap = sumGap+gap; } GC = C - sumGap; for cnt = 0 to 49{ VALUE1[cnt] = GC[cnt]; } For Nth = 0 to Period-1 { tempmax = -99999999; For cnt = 0 to Period-1{ if VALUE1[cnt] > tempmax then{ tempmax = VALUE1[cnt]; tempIndex = cnt; NTHVALUE[cnt] = Nth+1; } } VALUE1[tempIndex] = -99999999; } X1 = 0; for cnt = 0 to period-1{ X1 = X1+abs((cnt+1)-NTHVALUE[cnt])^2; } GRCI = (1-(6*X1)/(period*(period^2-1)))*100; 2. input : P1(9),P2(13),P3(18),P4(26); plot1(GRCI(P1)); plot2(GRCI(P2)); plot3(GRCI(P3)); plot4(GRCI(P4)); plotbaseline1(80,"baseline",gray); Plotbaseline1(-80,"baseline",gray); 즐거운 하루되세요 > 뉴스타트 님이 쓴 글입니다. > 제목 : 수정부탁합니다. > 하이에서 사용중입니다. 24104 관련하여 답변주신것을 갭보정으로 수정해주세요. 수고하세요.