Added csv output mode, fix delemitr problem