Merge pull request #11 from pakozm/devel

Devel
Added protected call for statistics computation
Added ternary operator when computing statistics