为什么我们将偏斜的数据转换为正态分布
我正在针对Kaggle(人类模拟的房价内核:高级回归技术)上的房价竞争解决方案,遇到了以下部分: # Transform the skewed numeric features by taking log(feature + 1). # This will make the features more normal. from scipy.stats import skew skewed = train_df_munged[numeric_features].apply(lambda x: skew(x.dropna().astype(float))) skewed = skewed[skewed > 0.75] skewed = skewed.index train_df_munged[skewed] = np.log1p(train_df_munged[skewed]) test_df_munged[skewed] = np.log1p(test_df_munged[skewed]) 我不确定将偏斜的分布转换为正态分布的需求。请有人可以详细解释一下: 为什么在这里这样做?或这有什么帮助? 这与功能扩展有何不同? 这是功能设计的必要步骤吗?如果我跳过此步骤,可能会发生什么?