diff --git a/createWERandSRRFiles.py b/createWERandSRRFiles.py index 9b91b3c..6e7946e 100644 --- a/createWERandSRRFiles.py +++ b/createWERandSRRFiles.py @@ -30,14 +30,14 @@ with open("helper.txt", "r") as f: werArray.append(sum) wer.write(lastId + " = " + str(sum) + "%\n") -wer.write("AVG: " + str(float((globalPercent) / (float(counter) * 100)*100)) + "%") -ssr.write(str(float(ssrCounter)/float(counter) * 100) + "%") +wer.write("AVG: " + str(float((globalPercent) / (float(counter) * 100)*100)) + "%\n\n\n\n") +ssr.write(str(float(ssrCounter)/float(counter) * 100) + "%\n") wer.close() ssr.close() with open('wikiniews_results.tsv','r') as f_in: - with open('wikiniews_resultsWithAdditionalColumn.tsv', 'a') as f_out: + with open('wikiniews_resultsWithAdditionalColumn.tsv', 'r') as f_out: writer = csv.writer(f_out, delimiter=' ', lineterminator='\n') reader = csv.reader(f_in, delimiter=' ')