Added header to output (and some documentation changes