Skip to content
This repository has been archived by the owner on Apr 19, 2022. It is now read-only.

Commit

Permalink
Fertigstellung der Funktion writestatsincsv
Browse files Browse the repository at this point in the history
  • Loading branch information
Tronde committed Jan 26, 2016
1 parent a9c6d68 commit 1d72a78
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions calc_avgminmax.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ def debug():
debug()

def writestatsincsv(temp_avg,min_t,max_t,humid_avg,min_h,max_h):
row = temp_avg + "," + min_t + "," + max_t + "," + humid_avg + "," + min_h + "," + max_h + "\n"
row = str("%2.1f" % temp_avg) + "," + min_t[0] + "," + min_t[tempitem] + "," + max_t[0] + "," + max_t[tempitem] + "," + str("%2.1f" % humid_avg) + "," + min_h[0] + "," + min_h[humiditem] + "," + max_h[0] + "," + max_h[humiditem] + "\n"
f = open('statistic_data.csv', 'w')
f.write(row)
f.close()
writestatsincsv(str("%2.1f" % temp_avg),str(min_t),str(max_t),str("%d" % humid_avg),str(min_h),str(max_h))
writestatsincsv(temp_avg,min_t,max_t,humid_avg,min_h,max_h)

sys.exit(0)

0 comments on commit 1d72a78

Please sign in to comment.