修复美团
This commit is contained in:
@@ -31,8 +31,7 @@ for city in cities:
|
||||
action['curr_city'] = city
|
||||
action['count'] = len(temp_df)
|
||||
for item in result_df.columns:
|
||||
if item == 'deal_num' or item == 'school' or item == 'market' or item == 'subway' \
|
||||
or item == 'bank' or item == 'hospital':
|
||||
if type(result_df[item]) == int or type(result_df[item]) == float:
|
||||
action[item] = round(len(temp_df[temp_df[item] > 0]) * 100 / len(temp_df), 2)
|
||||
else:
|
||||
action[item] = round(len(temp_df[temp_df[item].notna()]) * 100 / len(temp_df), 2)
|
||||
|
||||
Reference in New Issue
Block a user