Analytics

Prorealtime Code Library - Annual % Returns
Robustness Testing

Annual % Returns

  capital = 10000 once lastcapital = capital runningperc = ((strategyprofit – laststrategyprofit) / lastcapital) * 100 if year <> year[1] then annualreturn = runningperc[1] laststrategyprofit = strategyprofit lastcapital = capital + strategyprofit endif alltime = (strategyprofit / capital) * 100 graph runningperc coloured(0,128,0) as “Running % Return” graph annualreturn […]