优化报错

This commit is contained in:
沈健
2025-03-06 11:19:01 +08:00
parent 2e806a81cb
commit fd586603d9
@@ -23,6 +23,8 @@ def calc_percentile(city=None):
community_summary_df = es206_client.scan_by_sql_to_data_frame(sql)
community_summary_df['estate_charge_fix'] = community_summary_df['estate_charge'].combine_first(community_summary_df['estate_charge_fix'])
community_summary_df['relative_price_ranking'] = community_summary_df['relative_price_ranking'] * 100
if 'rent_price' not in community_summary_df.columns:
community_summary_df['rent_price'] = 0
consumption_aim_df = community_summary_df[['id', 'city', 'avg_price', 'total_price', 'avg_cost', 'rent_price', 'relative_price_ranking', 'finish_building_date',
'estate_charge_fix', 'household_count', 'build_area']]
number = []