fork|fork from Datawhale 零基础入门数据挖掘-Task3 特征工程

【fork|fork from Datawhale 零基础入门数据挖掘-Task3 特征工程】参考
特征构造
fork|fork from Datawhale 零基础入门数据挖掘-Task3 特征工程
文章图片

# 从邮编中提取城市信息,相当于加入了先验知识 data['city'] = data['regionCode'].apply(lambda x : str(x)[:-3]) data = https://www.it610.com/article/data

特征筛选
过滤式
# 相关性分析 print(data['power'].corr(data['price'], method='spearman')) print(data['kilometer'].corr(data['price'], method='spearman')) print(data['brand_amount'].corr(data['price'], method='spearman')) print(data['brand_price_average'].corr(data['price'], method='spearman')) print(data['brand_price_max'].corr(data['price'], method='spearman')) print(data['brand_price_median'].corr(data['price'], method='spearman'))

包裹式
嵌入式

    推荐阅读