커뮤니티
식
2004-06-19 00:18:52
1005
글번호 4152
Input : Period1(10), Period2(11), Period3(12), Period4(13), Period5(14),
Period6(15), Period7(16), Period8(17), Period9(18);
Plot1(ma(C,Period1), "이동평균1");
Plot2(ma(C,Period2), "이동평균2");
Plot3(ma(C,Period3), "이동평균3");
Plot4(ma(C,Period4), "이동평균4");
Plot5(ma(C,Period5), "이동평균5");
Plot6(ma(C,Period6), "이동평균6");
Plot7(ma(C,Period7), "이동평균7");
Plot8(ma(C,Period8), "이동평균8");
Plot9(ma(C,Period9), "이동평균9");
/* 상단 돌파시 다음 시가에 매수
하단 이탈시 다음 시가에 매도
상단 돌파시 매수(지정가)--봉완성전 매수
하단 이탈시 매도(지정가)--봉완성전 매도
답변 1
예스스탁 예스스탁 답변
2004-06-21 14:29:20
안녕하세요? 예스스탁입니다...
문의하신 식은 다음과 같습니다..
Input : Period1(10), Period2(11), Period3(12), Period4(13), Period5(14),
Period6(15), Period7(16), Period8(17), Period9(18);
var : 이평1(0), 이평2(0), 이평3(0), 이평4(0), 이평5(0), 이평6(0), 이평7(0), 이평8(0), 이평9(0);
이평1 = ma(C,Period1);
이평2 = ma(C,Period2);
이평3 = ma(C,Period3);
이평4 = ma(C,Period4);
이평5 = ma(C,Period5);
이평6 = ma(C,Period6);
이평7 = ma(C,Period7);
이평8 = ma(C,Period8);
이평9 = ma(C,Period9);
if crossup(c, max(이평1, 이평2, 이평3, 이평4, 이평5, 이평6, 이평7, 이평8, 이평9)) then
buy("매수", atmarket);
if crossdown(c, min(이평1, 이평2, 이평3, 이평4, 이평5, 이평6, 이평7, 이평8, 이평9)) then
sell("매도", atmarket);
감사합니다....
> HH_sos123 님이 쓴 글입니다.
> 제목 : 식
> Input : Period1(10), Period2(11), Period3(12), Period4(13), Period5(14),
Period6(15), Period7(16), Period8(17), Period9(18);
Plot1(ma(C,Period1), "이동평균1");
Plot2(ma(C,Period2), "이동평균2");
Plot3(ma(C,Period3), "이동평균3");
Plot4(ma(C,Period4), "이동평균4");
Plot5(ma(C,Period5), "이동평균5");
Plot6(ma(C,Period6), "이동평균6");
Plot7(ma(C,Period7), "이동평균7");
Plot8(ma(C,Period8), "이동평균8");
Plot9(ma(C,Period9), "이동평균9");
/* 상단 돌파시 다음 시가에 매수
하단 이탈시 다음 시가에 매도
상단 돌파시 매수(지정가)--봉완성전 매수
하단 이탈시 매도(지정가)--봉완성전 매도