커뮤니티

수식작성 부탁드립니다.

프로필 이미지
고박사122
2025-10-05 23:48:39.0
78
글번호 194511
답변완료
안녕하세요 운영자님 아래 이격도 지표의 선의 색을 지표속성창에서 단계별로 색을 변경할수 있도록 부탁드립니다. 즉, 101.0 ~100.5, 100.5~100, 100~99.5, 99.5~99.0 각각의 구간에서의 선의 색을 다르게 변경할 수 있도록 지표속성창에서 선의 색깔을 변경할 수 있도록 부탁드립니다. Input : Period(20); var : DParity(0); DParity = Disparity(Period); Plot1(DParity, "이격도"); PlotBaseLine1(101.0,"101.0"); PlotBaseLine2(100.5,"100.5"); PlotBaseLine3(100,"기준선"); PlotBaseLine4(99.5,"99.5"); PlotBaseLine5(99.0,"99.0");
지표
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2025-10-10 09:43:49.0

안녕하세요 예스스탁입니다. Input : Period(20); input : 상승색1(Pink),상승색2(Magenta),상승색3(red); input : 하락색1(LightBlue),하락색2(Cyan),하락색3(Blue); var : DParity(0),clr(0); DParity = Disparity(Period); if DParity >= 100 and DParity < 100.5 Then clr = 상승색1; if DParity >= 100.5 and DParity < 101 Then clr = 상승색2; if DParity >= 101 Then clr = 상승색3; if DParity < 100 and DParity > 99.5 Then clr = 하락색1; if DParity <= 99.5 and DParity > 99 Then clr = 하락색2; if DParity <= 99 Then clr = 하락색3; Plot1(DParity, "이격도",clr); PlotBaseLine1(101.0,"101.0"); PlotBaseLine2(100.5,"100.5"); PlotBaseLine3(100,"기준선"); PlotBaseLine4(99.5,"99.5"); PlotBaseLine5(99.0,"99.0"); 즐거운 하루되세요 > 고박사122 님이 쓴 글입니다. > 제목 : 수식작성 부탁드립니다. > 안녕하세요 운영자님 아래 이격도 지표의 선의 색을 지표속성창에서 단계별로 색을 변경할수 있도록 부탁드립니다. 즉, 101.0 ~100.5, 100.5~100, 100~99.5, 99.5~99.0 각각의 구간에서의 선의 색을 다르게 변경할 수 있도록 지표속성창에서 선의 색깔을 변경할 수 있도록 부탁드립니다. Input : Period(20); var : DParity(0); DParity = Disparity(Period); Plot1(DParity, "이격도"); PlotBaseLine1(101.0,"101.0"); PlotBaseLine2(100.5,"100.5"); PlotBaseLine3(100,"기준선"); PlotBaseLine4(99.5,"99.5"); PlotBaseLine5(99.0,"99.0");