cleaning up, add doc
var output file