Commit 59cae1d0 authored by 王志伟's avatar 王志伟

change temp

parent 450840bf
......@@ -50,11 +50,12 @@ def ctr(date):
print("点击率:"+str(click/exp))
return click,exp,click/exp
temp_data = ctr(date)
def rate2file():
output_path = DIRECTORY_PATH + "rate.csv"
with open(output_path,'a+') as f:
line = get_yesterday_date().replace('-', '')+','+str(ctr(date)[0])+','+str(ctr(date)[1])+','+str(ctr(date)[2])+'\n'
line = get_yesterday_date().replace('-', '')+','+str(temp_data[0])+','+str(temp_data[1])+','+str(temp_data[2])+'\n'
f.write(line)
if __name__ == "__main__":
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment