Trubchevsk
Experience: Beginner
Platform: tos
Trading: stocks
Posts: 61 since May 2011
Thanks Given: 40
Thanks Received: 79
|
input length = 70;
def green = fold i=0 to length with n = 0 do if getvalue(close-open,i, length)>0 then n+(close-open) else green[1];
def red = fold j=0 to length with k = 0 do if getvalue(open-close,j, length)<0 then k+(open-close) else red[1];
plot ratio =(green-red);
|