커뮤니티

보내주신 수식 살짝수정하고십습니다.

프로필 이미지
열라빠른거북이
2016-06-16 19:41:04
109
글번호 99184
답변완료
보내주신 수식 잘 사용하고 있습니다. 살짝 수정해보려고 하는데요 다음 신호 이후 상승일 경우에는 스토K선이 바로 이전 고점보다 크거나 같을때 상승신호가 찍히도록(아래수식의 상승신호는 없앱니다.) 하락일 경우에는 스토K선이 바로 이전 저점보다 작거나 같을때 하락신호가 찍히도록(아래수식의 하락신호는 없앱니다.) Input : Period(5), Period1(3), Period2(3); var : StoK(0),StoD(0),T(0); var : Hi1(0),Hi2(0),HH1(0),HH2(0); var : Li1(0),Li2(0),LL1(0),LL2(0); StoK = StochasticsK(Period,Period1); StoD = StochasticsD(Period,Period1,Period2); if crossup(stok,stod) Then{ T = 1; Hi1 = stok; Hi2 = Hi1[1]; HH1 = H; HH2 = HH1[1]; if Li1 < Li2 and LL1 < LL2 and LL2 > 0 Then and Hi1 < Hi2 and HH1 < HH2 and HH2 > 0 Then buy(); } if T == 1 Then{ if stok > Hi1 Then Hi1 = stok; if H > HH1 Then HH1 = H; } if CrossDown(stok,stod) Then{ T = -1; Li1 = stok; Li2 = Li1[1]; LL1 = L; LL2 = LL1[1]; if Li1 > Li2 and LL1 > LL2 and LL2 > 0 Then and Hi1 > Hi2 and HH1 > HH2 and HH2 > 0 Then sell(); } if T == -1 Then{ if stok < Li1 Then Li1 = stok; if L < LL1 Then LL1 = L; }
지표
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2016-06-17 10:20:25

안녕하세요 예스스탁입니다. Input : Period(5), Period1(3), Period2(3); var : StoK(0),StoD(0),T(0); var : Hi1(0),Hi2(0),HH1(0),HH2(0); var : Li1(0),Li2(0),LL1(0),LL2(0); StoK = StochasticsK(Period,Period1); StoD = StochasticsD(Period,Period1,Period2); if crossup(stok,stod) Then{ T = 1; Hi1 = stok; Hi2 = Hi1[1]; HH1 = H; HH2 = HH1[1]; } if T == 1 Then{ if stok > Hi1 Then Hi1 = stok; if H > HH1 Then HH1 = H; if Hi1 >= Hi2 and Hi2 > 0 Then buy(); } if CrossDown(stok,stod) Then{ T = -1; Li1 = stok; Li2 = Li1[1]; LL1 = L; LL2 = LL1[1]; } if T == -1 Then{ if stok < Li1 Then Li1 = stok; if L < LL1 Then LL1 = L; if Li1 <= Li2 and Li2 > 0 Then sell(); } 즐거운 하루되세요 > 열라빠른거북이 님이 쓴 글입니다. > 제목 : 보내주신 수식 살짝수정하고십습니다. > 보내주신 수식 잘 사용하고 있습니다. 살짝 수정해보려고 하는데요 다음 신호 이후 상승일 경우에는 스토K선이 바로 이전 고점보다 크거나 같을때 상승신호가 찍히도록(아래수식의 상승신호는 없앱니다.) 하락일 경우에는 스토K선이 바로 이전 저점보다 작거나 같을때 하락신호가 찍히도록(아래수식의 하락신호는 없앱니다.) Input : Period(5), Period1(3), Period2(3); var : StoK(0),StoD(0),T(0); var : Hi1(0),Hi2(0),HH1(0),HH2(0); var : Li1(0),Li2(0),LL1(0),LL2(0); StoK = StochasticsK(Period,Period1); StoD = StochasticsD(Period,Period1,Period2); if crossup(stok,stod) Then{ T = 1; Hi1 = stok; Hi2 = Hi1[1]; HH1 = H; HH2 = HH1[1]; if Li1 < Li2 and LL1 < LL2 and LL2 > 0 Then and Hi1 < Hi2 and HH1 < HH2 and HH2 > 0 Then buy(); } if T == 1 Then{ if stok > Hi1 Then Hi1 = stok; if H > HH1 Then HH1 = H; } if CrossDown(stok,stod) Then{ T = -1; Li1 = stok; Li2 = Li1[1]; LL1 = L; LL2 = LL1[1]; if Li1 > Li2 and LL1 > LL2 and LL2 > 0 Then and Hi1 > Hi2 and HH1 > HH2 and HH2 > 0 Then sell(); } if T == -1 Then{ if stok < Li1 Then Li1 = stok; if L < LL1 Then LL1 = L; }