07/10/31 23:02:33.97 2PwZb44V
>>187
適当だけど手直ししたよん
コメントの中味ひょっとして上限と下限入れたいんじゃない?
#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 Red
#property indicator_color2 Blue
double line1[], line2[];
int init() {
SetIndexBuffer(0,line1);
SetIndexBuffer(1,line2);
SetIndexDrawBegin(0, 10);
return(0);
}
double calcClose(int i) {
return(Close[i]+0.1);
}
int start() {
double a;
int i, limit = Bars - IndicatorCounted();
a=Close[0]-0.1;
for (i=limit-1; i>=0; i--) {
line1[i] = calcClose(i);
line2[i] = Close[i]-0.1;
}
Comment("temp1[0]=",a , " calcClose=", calcClose(0));
return(0);
}