import pandas as pd
import matplotlib as plt
import numpy as np
train=pd.read_csv("train.csv")
# 移除无用特征
train=train.drop(["ID"],axis=1)
#数据都为RG+数字,现将RG除去,只留数字
train['Region_Code']=train['Region_Code'].apply(lambda x:x[2:]).astype('int64')
# 可视化各项指标
import seaborn as sns
import matplotlib.pyplot as plt
plt.figure(figsize=(20, 6))
sns.countplot(x = "Age", data = train)
<Axes: xlabel='Age', ylabel='count'>
plt.figure(figsize=(20, 6))
sns.countplot(x = "Vintage", data = train)
<Axes: xlabel='Vintage', ylabel='count'>
plt.figure(figsize=(20, 6))
sns.countplot(x = "Occupation", data = train)
<Axes: xlabel='Occupation', ylabel='count'>
sns.countplot(x = "Credit_Product", data = train)
<Axes: xlabel='Credit_Product', ylabel='count'>
sns.countplot(x = "Is_Active", data = train)
<Axes: xlabel='Is_Active', ylabel='count'>
sns.countplot(x = "Is_Lead", data = train)
# 问题出现了,需要预测的部分Is_Lead=1的样本量太少了,需要欠采样多数类
<Axes: xlabel='Is_Lead', ylabel='count'>
sns.countplot(x = "Channel_Code", data = train)
<Axes: xlabel='Channel_Code', ylabel='count'>
from sklearn.utils import resample
# 欠采样多数类
df_majority = train[train['Is_Lead']==0]
df_minority = train[train['Is_Lead']==1]
df_majority_undersampled = resample(df_majority,replace=True,n_samples=len(df_minority),random_state=0)
# 结合少数类和过采样的多数类
df_undersampled = pd.concat([df_minority, df_majority_undersampled])
df_undersampled['Is_Lead'].value_counts()
train=df_undersampled
# 将Gender、Credit_Product、Is_Active改为0,1表示
train["Gender"] = train["Gender"].replace({"Male": 1, "Female": 0}).astype("int32")
train["Is_Active"] = train["Is_Active"].replace({"Yes": 1, "No": 0}).astype("int32")
train["Credit_Product"] = train["Credit_Product"].replace({"Yes": 1, "No": 0})
train
Gender | Age | Region_Code | Occupation | Channel_Code | Vintage | Credit_Product | Avg_Account_Balance | Is_Active | Is_Lead | |
---|---|---|---|---|---|---|---|---|---|---|
4 | 0 | 84 | 279 | Other | X2 | 93 | 0.0 | 555199 | 0 | 1 |
11 | 0 | 28 | 270 | Salaried | X1 | 27 | 0.0 | 743781 | 0 | 1 |
23 | 0 | 56 | 254 | Self_Employed | X2 | 97 | NaN | 3360390 | 1 | 1 |
26 | 1 | 42 | 251 | Self_Employed | X2 | 15 | 0.0 | 327555 | 1 | 1 |
34 | 1 | 48 | 276 | Self_Employed | X3 | 33 | 0.0 | 1680907 | 1 | 1 |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
116375 | 1 | 49 | 268 | Self_Employed | X2 | 92 | 1.0 | 1763846 | 0 | 0 |
162838 | 1 | 32 | 252 | Salaried | X1 | 26 | 0.0 | 1016709 | 0 | 0 |
27157 | 1 | 48 | 282 | Self_Employed | X3 | 91 | 0.0 | 912775 | 0 | 0 |
84102 | 1 | 36 | 267 | Salaried | X3 | 33 | 0.0 | 523951 | 0 | 0 |
16567 | 0 | 27 | 254 | Other | X1 | 26 | 0.0 | 870064 | 0 | 0 |
93154 rows × 10 columns
# 将Occupation进行one-hot编码
encoded_data = pd.get_dummies(train["Occupation"], prefix="Occupation").replace({True: 1, False: 0})
train = pd.concat([train.iloc[:, :-1], encoded_data, train.iloc[:, -1]], axis=1)
train=train.drop(["Occupation"],axis=1)
train
Gender | Age | Region_Code | Channel_Code | Vintage | Credit_Product | Avg_Account_Balance | Is_Active | Occupation_Entrepreneur | Occupation_Other | Occupation_Salaried | Occupation_Self_Employed | Is_Lead | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4 | 0 | 84 | 279 | X2 | 93 | 0.0 | 555199 | 0 | 0 | 1 | 0 | 0 | 1 |
11 | 0 | 28 | 270 | X1 | 27 | 0.0 | 743781 | 0 | 0 | 0 | 1 | 0 | 1 |
23 | 0 | 56 | 254 | X2 | 97 | NaN | 3360390 | 1 | 0 | 0 | 0 | 1 | 1 |
26 | 1 | 42 | 251 | X2 | 15 | 0.0 | 327555 | 1 | 0 | 0 | 0 | 1 | 1 |
34 | 1 | 48 | 276 | X3 | 33 | 0.0 | 1680907 | 1 | 0 | 0 | 0 | 1 | 1 |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
116375 | 1 | 49 | 268 | X2 | 92 | 1.0 | 1763846 | 0 | 0 | 0 | 0 | 1 | 0 |
162838 | 1 | 32 | 252 | X1 | 26 | 0.0 | 1016709 | 0 | 0 | 0 | 1 | 0 | 0 |
27157 | 1 | 48 | 282 | X3 | 91 | 0.0 | 912775 | 0 | 0 | 0 | 0 | 1 | 0 |
84102 | 1 | 36 | 267 | X3 | 33 | 0.0 | 523951 | 0 | 0 | 0 | 1 | 0 | 0 |
16567 | 0 | 27 | 254 | X1 | 26 | 0.0 | 870064 | 0 | 0 | 1 | 0 | 0 | 0 |
93154 rows × 13 columns
# 将Channel_Code进行one-hot编码
train = pd.get_dummies(train, columns=['Channel_Code'], prefix=['X']).replace({True: 1, False: 0})
# 获取倒数第五列的列名
column_to_move = train.columns[-5]
# 将倒数第五列保存到变量中
column_data = train[column_to_move]
# 删除倒数第五列
train = train.drop(column_to_move, axis=1)
# 将倒数第五列重新添加到DataFrame的最后
train[column_to_move] = column_data
train
Gender | Age | Region_Code | Vintage | Credit_Product | Avg_Account_Balance | Is_Active | Occupation_Entrepreneur | Occupation_Other | Occupation_Salaried | Occupation_Self_Employed | X_X1 | X_X2 | X_X3 | X_X4 | Is_Lead | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4 | 0 | 84 | 279 | 93 | 0.0 | 555199 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
11 | 0 | 28 | 270 | 27 | 0.0 | 743781 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 1 |
23 | 0 | 56 | 254 | 97 | NaN | 3360390 | 1 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 1 |
26 | 1 | 42 | 251 | 15 | 0.0 | 327555 | 1 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 1 |
34 | 1 | 48 | 276 | 33 | 0.0 | 1680907 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 1 |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
116375 | 1 | 49 | 268 | 92 | 1.0 | 1763846 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 |
162838 | 1 | 32 | 252 | 26 | 0.0 | 1016709 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 |
27157 | 1 | 48 | 282 | 91 | 0.0 | 912775 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 |
84102 | 1 | 36 | 267 | 33 | 0.0 | 523951 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 |
16567 | 0 | 27 | 254 | 26 | 0.0 | 870064 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 |
93154 rows × 16 columns
#查看各特征值与是否可能成为信用卡客户的相关性
df_corr_lead=train.corr()[u'Is_Lead'].sort_values(ascending=False)
df_corr_lead=df_corr_lead.drop(['Is_Lead'],axis=0)
#对其进行可视化
plt.figure(figsize=(30,12),)
plt.bar(list(df_corr_lead.index),df_corr_lead.values)
for i,j in zip(list(df_corr_lead.index),df_corr_lead.values):
plt.text(i,j,'%s'%('{:.3f}'.format(j)),ha='center',size=15)
plt.show()
# 判断是否存在缺失值
pd.isnull(train).any()
# 发现Credit_Product部分缺失,采用预测的方式进行填补
Gender False Age False Region_Code False Vintage False Credit_Product True Avg_Account_Balance False Is_Active False Occupation_Entrepreneur False Occupation_Other False Occupation_Salaried False Occupation_Self_Employed False X_X1 False X_X2 False X_X3 False X_X4 False Is_Lead False dtype: bool
# 筛选空值部分
missing_credit_product = train[train["Credit_Product"].isnull()]
# 筛选非空值部分
non_missing_credit_product = train[train["Credit_Product"].notnull()]
#查看各特征值与是否可能成为信用卡客户的相关性
df_corr_lead=non_missing_credit_product.corr()[u'Credit_Product'].sort_values(ascending=False)
df_corr_lead=df_corr_lead.drop(['Is_Lead','Credit_Product'],axis=0)
#对其进行可视化
plt.figure(figsize=(30,12),)
plt.bar(list(df_corr_lead.index),df_corr_lead.values)
for i,j in zip(list(df_corr_lead.index),df_corr_lead.values):
plt.text(i,j,'%s'%('{:.3f}'.format(j)),ha='center',size=15)
plt.show()
# 对数据集进行划分
from sklearn.model_selection import train_test_split
data=non_missing_credit_product.drop(["Is_Lead", "Credit_Product"], axis=1)
x_train,x_test,y_train,y_test=train_test_split(data,non_missing_credit_product["Credit_Product"],test_size=0.2,random_state=22)
# 训练集与测试集标准化
from sklearn.preprocessing import StandardScaler
transfer=StandardScaler()
x_train_new=transfer.fit_transform(x_train)
x_test_new=transfer.transform(x_test)
# # 主成分分析降维
from sklearn.decomposition import PCA
# transfer=PCA(n_components=0.95)
# x_train_new=transfer.fit_transform(x_train_new)
# x_test_new=transfer.transform(x_test_new)
import lightgbm as lgb
from sklearn.metrics import roc_auc_score
# 创建LightGBM分类器
lgb_classifier = lgb.LGBMClassifier(n_estimators=80, random_state=40)
# 训练LightGBM分类器
lgb_classifier.fit(x_train_new, y_train)
# 在测试集上进行预测
y_pred_prob = lgb_classifier.predict_proba(x_test_new)[:, 1] # 预测样本属于正类的概率
# 计算AUC
auc_score = roc_auc_score(y_test, y_pred_prob)
print("AUC Score:", auc_score)
AUC Score: 0.7671483718923551
# 至此我们发现,采用lightgbm预估正确率最高,因此,采用此方法来填充空值
data=non_missing_credit_product.drop(["Is_Lead", "Credit_Product"], axis=1)
data_ans=non_missing_credit_product["Credit_Product"]
test=missing_credit_product.drop(["Is_Lead", "Credit_Product"], axis=1)
# 标准化
transfer=StandardScaler()
data_new=transfer.fit_transform(data)
test_new=transfer.transform(test)
# # 主成分分析降维
# transfer=PCA(n_components=0.95)
# data_new=transfer.fit_transform(data_new)
# test_new=transfer.transform(test_new)
lgb_classifier = lgb.LGBMClassifier(n_estimators=80, random_state=42)
# 训练LightGBM分类器
lgb_classifier.fit(data_new, data_ans)
# 在测试集上进行预测
y_pred_prob = lgb_classifier.predict_proba(test_new)[:,1] # 预测样本属于正类的概率
# 填充
y_pred_prob_series = pd.Series(y_pred_prob, index=missing_credit_product.index)
missing_credit_product.loc[missing_credit_product["Credit_Product"].isnull(), "Credit_Product"] = y_pred_prob_series
# 拼接回原来的训练集
train=pd.concat([missing_credit_product, non_missing_credit_product])
# 开始预测目标值
data=train.drop(["Is_Lead"], axis=1)
x_train,x_test,y_train,y_test=train_test_split(data,train["Is_Lead"],test_size=0.25,random_state=42)
# 训练集与测试集标准化
transfer=StandardScaler()
x_train_new=transfer.fit_transform(x_train)
x_test_new=transfer.transform(x_test)
from bayes_opt import BayesianOptimization
# Define the function to optimize (AUC score) using Bayesian optimization
def lgb_cv(n_estimators, learning_rate, max_depth, num_leaves, min_child_samples, subsample, colsample_bytree):
# Convert integer hyperparameters to integers
n_estimators = int(n_estimators)
max_depth = int(max_depth)
num_leaves = int(num_leaves)
min_child_samples = int(min_child_samples)
# Create a LightGBM classifier with the given hyperparameters
lgb_classifier = lgb.LGBMClassifier(
n_estimators=n_estimators,
learning_rate=learning_rate,
max_depth=max_depth,
num_leaves=num_leaves,
min_child_samples=min_child_samples,
subsample=subsample,
colsample_bytree=colsample_bytree,
random_state=40
)
# Train the classifier on the training data
lgb_classifier.fit(x_train_new, y_train)
# Make predictions on the test data
y_pred_prob = lgb_classifier.predict_proba(x_test_new)[:, 1]
# Calculate the AUC score
auc_score = roc_auc_score(y_test, y_pred_prob)
return auc_score
# Define the hyperparameter ranges for Bayesian optimization
pbounds = {
'n_estimators': (150, 220),
'learning_rate': (0.02, 0.09),
'max_depth': (10, 15),
'num_leaves': (20, 100),
'min_child_samples': (5, 50),
'subsample': (0.5, 0.7),
'colsample_bytree': (0.6, 1.0)
}
# Create the BayesianOptimization object with the function to optimize and the hyperparameter bounds
optimizer = BayesianOptimization(
f=lgb_cv,
pbounds=pbounds,
random_state=42
)
# Perform Bayesian optimization
optimizer.maximize(init_points=10, n_iter=100)
# Get the optimal hyperparameters and corresponding AUC score
best_params = optimizer.max['params']
best_auc = optimizer.max['target']
print("Optimal Hyperparameters:")
print(best_params)
print("Best AUC Score:", best_auc)
| iter | target | colsam... | learni... | max_depth | min_ch... | n_esti... | num_le... | subsample | ------------------------------------------------------------------------------------------------------------- | 1 | 0.8734 | 0.7498 | 0.08655 | 13.66 | 31.94 | 160.9 | 32.48 | 0.5116 | | 2 | 0.8748 | 0.9465 | 0.06208 | 13.54 | 5.926 | 217.9 | 86.6 | 0.5425 | | 3 | 0.8737 | 0.6727 | 0.03284 | 11.52 | 28.61 | 180.2 | 43.3 | 0.6224 | | 4 | 0.8738 | 0.6558 | 0.04045 | 11.83 | 25.52 | 205.0 | 35.97 | 0.6028 | | 5 | 0.8738 | 0.837 | 0.02325 | 13.04 | 12.67 | 154.6 | 95.91 | 0.6931 | | 6 | 0.8733 | 0.9234 | 0.04132 | 10.49 | 35.79 | 180.8 | 29.76 | 0.599 | | 7 | 0.874 | 0.6138 | 0.08365 | 11.29 | 34.81 | 171.8 | 61.61 | 0.6093 | | 8 | 0.8734 | 0.6739 | 0.08787 | 13.88 | 47.28 | 212.6 | 67.83 | 0.6844 | | 9 | 0.8739 | 0.6354 | 0.03372 | 10.23 | 19.64 | 177.2 | 41.71 | 0.6657 | | 10 | 0.8738 | 0.7427 | 0.03967 | 12.71 | 11.34 | 206.2 | 25.96 | 0.6974 | | 11 | 0.8746 | 0.7124 | 0.07015 | 14.43 | 5.014 | 198.1 | 81.36 | 0.542 | | 12 | 0.8737 | 0.6257 | 0.02763 | 14.48 | 43.25 | 202.6 | 42.31 | 0.5996 | | 13 | 0.874 | 0.7703 | 0.04386 | 14.52 | 26.26 | 216.0 | 43.78 | 0.6361 | | 14 | 0.8736 | 0.9994 | 0.02358 | 13.91 | 38.4 | 205.5 | 47.94 | 0.5929 | | 15 | 0.8745 | 0.8014 | 0.04505 | 13.5 | 5.988 | 218.5 | 88.25 | 0.5013 | | 16 | 0.875 | 0.8223 | 0.05303 | 14.97 | 6.37 | 217.5 | 83.72 | 0.6993 | | 17 | 0.8741 | 0.8913 | 0.04304 | 11.42 | 5.653 | 211.1 | 79.25 | 0.6315 | | 18 | 0.8746 | 0.6002 | 0.06954 | 12.52 | 12.02 | 219.9 | 81.73 | 0.5439 | | 19 | 0.8744 | 0.9756 | 0.04545 | 13.96 | 10.64 | 210.9 | 87.23 | 0.645 | | 20 | 0.8737 | 0.905 | 0.06268 | 12.57 | 6.198 | 218.9 | 80.1 | 0.6714 | | 21 | 0.8747 | 0.6232 | 0.07755 | 12.08 | 11.6 | 217.2 | 85.4 | 0.6758 | | 22 | 0.8747 | 0.6895 | 0.07514 | 14.99 | 8.508 | 216.5 | 85.29 | 0.5305 | | 23 | 0.8753 | 0.6996 | 0.03679 | 14.46 | 5.073 | 215.9 | 84.06 | 0.6093 | | 24 | 0.8742 | 0.8952 | 0.05149 | 13.56 | 5.241 | 211.5 | 83.69 | 0.578 | | 25 | 0.8741 | 0.8848 | 0.0596 | 10.69 | 15.64 | 219.9 | 85.7 | 0.6331 | | 26 | 0.874 | 0.6212 | 0.07173 | 10.86 | 12.13 | 213.9 | 83.68 | 0.6485 | | 27 | 0.8745 | 0.7315 | 0.06917 | 11.47 | 6.007 | 217.3 | 84.75 | 0.6004 | | 28 | 0.8751 | 0.7557 | 0.04125 | 14.81 | 11.88 | 215.1 | 90.89 | 0.5178 | | 29 | 0.8747 | 0.7723 | 0.07678 | 14.28 | 10.37 | 216.0 | 93.3 | 0.6447 | | 30 | 0.8744 | 0.7857 | 0.05494 | 13.44 | 15.64 | 215.3 | 90.32 | 0.6147 | | 31 | 0.8745 | 0.92 | 0.06649 | 13.9 | 8.149 | 213.1 | 90.06 | 0.6466 | | 32 | 0.8745 | 0.8119 | 0.07494 | 14.23 | 13.55 | 211.7 | 93.92 | 0.6124 | | 33 | 0.8744 | 0.6 | 0.09 | 15.0 | 11.77 | 218.2 | 89.36 | 0.7 | | 34 | 0.8742 | 0.895 | 0.08347 | 12.83 | 11.21 | 215.5 | 90.76 | 0.6061 | | 35 | 0.8751 | 0.6597 | 0.04563 | 14.73 | 12.94 | 211.1 | 91.38 | 0.646 | | 36 | 0.8743 | 0.7504 | 0.02135 | 14.94 | 12.33 | 214.2 | 87.38 | 0.5756 | | 37 | 0.8745 | 0.8825 | 0.04539 | 14.14 | 14.27 | 207.1 | 91.44 | 0.6077 | | 38 | 0.8752 | 0.6253 | 0.0795 | 14.62 | 11.91 | 214.2 | 93.05 | 0.6013 | | 39 | 0.8738 | 0.9372 | 0.03267 | 13.28 | 9.903 | 209.2 | 92.21 | 0.5008 | | 40 | 0.8744 | 0.7772 | 0.08631 | 14.12 | 12.91 | 216.2 | 96.2 | 0.6497 | | 41 | 0.8748 | 0.8146 | 0.06851 | 14.44 | 11.22 | 213.1 | 90.65 | 0.5733 | | 42 | 0.8747 | 0.6231 | 0.07336 | 14.2 | 12.8 | 213.4 | 92.05 | 0.6644 | | 43 | 0.8746 | 0.6494 | 0.06806 | 14.44 | 13.33 | 216.5 | 91.56 | 0.6972 | | 44 | 0.8748 | 0.9791 | 0.08346 | 13.78 | 6.643 | 215.0 | 84.97 | 0.5984 | | 45 | 0.8742 | 0.7886 | 0.07413 | 14.48 | 10.95 | 213.0 | 95.36 | 0.6686 | | 46 | 0.8742 | 0.7596 | 0.07788 | 11.75 | 10.55 | 219.3 | 83.94 | 0.5641 | | 47 | 0.8746 | 0.6756 | 0.02833 | 13.49 | 15.83 | 210.7 | 89.41 | 0.5021 | | 48 | 0.8744 | 0.63 | 0.02798 | 14.0 | 15.38 | 209.6 | 92.5 | 0.5348 | | 49 | 0.875 | 0.8137 | 0.07083 | 14.65 | 6.137 | 215.1 | 87.86 | 0.5007 | | 50 | 0.8744 | 0.9191 | 0.05873 | 14.79 | 5.083 | 214.4 | 81.14 | 0.5918 | | 51 | 0.8745 | 0.9163 | 0.06364 | 13.57 | 14.65 | 219.8 | 78.71 | 0.6571 | | 52 | 0.8744 | 0.9472 | 0.07874 | 14.79 | 14.37 | 217.7 | 81.24 | 0.5633 | | 53 | 0.8742 | 0.7956 | 0.06696 | 11.6 | 5.409 | 214.1 | 89.53 | 0.5687 | | 54 | 0.8743 | 0.8097 | 0.06567 | 13.67 | 5.06 | 216.8 | 86.38 | 0.6274 | | 55 | 0.8746 | 0.8226 | 0.06416 | 14.35 | 8.553 | 218.1 | 85.89 | 0.6583 | | 56 | 0.8745 | 0.8056 | 0.04099 | 14.09 | 5.906 | 216.5 | 84.59 | 0.671 | | 57 | 0.8742 | 0.8053 | 0.02318 | 12.67 | 8.146 | 216.7 | 85.79 | 0.6145 | | 58 | 0.8751 | 0.8743 | 0.03616 | 15.0 | 13.5 | 211.5 | 90.18 | 0.5 | | 59 | 0.8742 | 0.9308 | 0.03037 | 13.63 | 6.562 | 213.2 | 86.4 | 0.5806 | | 60 | 0.8747 | 0.7161 | 0.03201 | 14.29 | 8.196 | 215.1 | 89.02 | 0.6161 | | 61 | 0.8749 | 0.632 | 0.06484 | 12.5 | 6.597 | 219.9 | 86.28 | 0.5258 | | 62 | 0.8747 | 0.8629 | 0.08885 | 13.72 | 6.881 | 214.5 | 83.6 | 0.663 | | 63 | 0.8747 | 0.9029 | 0.03119 | 14.99 | 11.65 | 215.9 | 94.67 | 0.5856 | | 64 | 0.8748 | 0.6282 | 0.05371 | 14.61 | 5.019 | 215.3 | 82.19 | 0.6261 | | 65 | 0.8737 | 0.9841 | 0.08831 | 14.56 | 5.695 | 219.4 | 86.62 | 0.6388 | | 66 | 0.8747 | 0.8082 | 0.06228 | 14.46 | 7.694 | 216.7 | 82.84 | 0.5904 | | 67 | 0.8742 | 0.7953 | 0.05921 | 14.73 | 7.589 | 218.9 | 84.19 | 0.5339 | | 68 | 0.8747 | 0.9383 | 0.03091 | 14.6 | 9.09 | 215.2 | 83.98 | 0.5664 | | 69 | 0.8744 | 0.7433 | 0.06533 | 14.77 | 13.16 | 215.0 | 91.8 | 0.6959 | | 70 | 0.8743 | 0.6451 | 0.0207 | 13.45 | 11.34 | 214.6 | 92.95 | 0.5836 | | 71 | 0.8753 | 0.7226 | 0.06007 | 14.66 | 10.97 | 215.0 | 89.98 | 0.6399 | | 72 | 0.8743 | 0.9938 | 0.07436 | 14.68 | 9.313 | 216.3 | 87.29 | 0.5776 | | 73 | 0.874 | 0.9748 | 0.07583 | 13.9 | 14.43 | 212.6 | 90.3 | 0.5152 | | 74 | 0.8744 | 0.7307 | 0.02372 | 14.84 | 11.83 | 214.3 | 90.69 | 0.5307 | | 75 | 0.8744 | 0.961 | 0.08507 | 14.93 | 11.63 | 211.5 | 90.48 | 0.5398 | | 76 | 0.8742 | 0.9387 | 0.04062 | 13.67 | 10.42 | 212.9 | 90.44 | 0.5167 | | 77 | 0.8747 | 0.9462 | 0.06496 | 14.98 | 9.483 | 214.0 | 90.48 | 0.6503 | | 78 | 0.8748 | 0.6325 | 0.07283 | 13.27 | 12.67 | 210.6 | 90.98 | 0.6301 | | 79 | 0.8744 | 0.8623 | 0.04145 | 14.69 | 9.27 | 217.2 | 84.96 | 0.6807 | | 80 | 0.8748 | 0.8571 | 0.05822 | 13.84 | 12.55 | 212.1 | 92.87 | 0.6403 | | 81 | 0.8744 | 0.8831 | 0.07051 | 14.74 | 10.45 | 215.1 | 89.62 | 0.5941 | | 82 | 0.8744 | 0.66 | 0.05258 | 14.17 | 35.36 | 186.6 | 76.76 | 0.6016 | | 83 | 0.8744 | 0.8986 | 0.06332 | 13.63 | 7.139 | 216.9 | 82.52 | 0.6816 | | 84 | 0.8747 | 0.6495 | 0.04659 | 11.62 | 7.195 | 178.1 | 61.46 | 0.6958 | | 85 | 0.8747 | 0.7534 | 0.08182 | 13.27 | 5.733 | 215.1 | 87.0 | 0.6505 | | 86 | 0.8751 | 0.668 | 0.05366 | 13.99 | 6.288 | 214.6 | 88.31 | 0.5067 | | 87 | 0.8734 | 0.9939 | 0.08022 | 13.06 | 5.231 | 214.4 | 87.75 | 0.58 | | 88 | 0.8748 | 0.9781 | 0.0565 | 14.86 | 12.92 | 211.7 | 90.21 | 0.6131 | | 89 | 0.8747 | 0.7613 | 0.07047 | 14.14 | 11.54 | 213.5 | 91.76 | 0.584 | | 90 | 0.8741 | 0.8456 | 0.02431 | 13.99 | 12.98 | 211.3 | 92.18 | 0.6626 | | 91 | 0.8739 | 0.9985 | 0.0696 | 12.48 | 12.17 | 216.5 | 85.21 | 0.6277 | | 92 | 0.8745 | 0.6555 | 0.08594 | 13.62 | 8.912 | 215.2 | 82.78 | 0.5465 | | 93 | 0.8731 | 0.9326 | 0.08337 | 13.47 | 48.39 | 167.0 | 52.2 | 0.6685 | | 94 | 0.8735 | 0.7645 | 0.07311 | 10.61 | 45.97 | 191.9 | 33.88 | 0.5132 | | 95 | 0.874 | 0.9073 | 0.05692 | 13.63 | 32.84 | 197.7 | 64.32 | 0.6277 | | 96 | 0.8739 | 0.6939 | 0.06224 | 12.14 | 24.31 | 193.0 | 94.21 | 0.5147 | | 97 | 0.8745 | 0.7277 | 0.03087 | 13.6 | 5.01 | 217.1 | 84.45 | 0.5553 | | 98 | 0.8746 | 0.6408 | 0.02641 | 14.31 | 10.95 | 215.6 | 94.29 | 0.5391 | | 99 | 0.8751 | 0.6559 | 0.05133 | 14.74 | 13.15 | 212.1 | 92.64 | 0.5069 | | 100 | 0.8756 | 0.6109 | 0.08053 | 13.71 | 7.263 | 215.9 | 87.0 | 0.6203 | | 101 | 0.8746 | 0.9861 | 0.05746 | 14.85 | 13.42 | 211.9 | 90.86 | 0.5079 | | 102 | 0.8743 | 0.8844 | 0.0206 | 14.27 | 5.322 | 215.4 | 82.88 | 0.5666 | | 103 | 0.8742 | 0.8053 | 0.08119 | 14.35 | 6.977 | 215.7 | 84.78 | 0.642 | | 104 | 0.8748 | 0.8164 | 0.06701 | 15.0 | 8.916 | 216.3 | 85.07 | 0.5066 | | 105 | 0.875 | 0.6301 | 0.0881 | 12.55 | 7.67 | 216.0 | 88.0 | 0.6923 | | 106 | 0.8749 | 0.6827 | 0.07945 | 14.03 | 11.88 | 211.2 | 89.78 | 0.6455 | | 107 | 0.8743 | 0.64 | 0.04904 | 11.5 | 48.04 | 183.8 | 53.34 | 0.63 | | 108 | 0.8735 | 0.7001 | 0.0673 | 14.01 | 46.95 | 179.4 | 39.14 | 0.6673 | | 109 | 0.8742 | 0.8836 | 0.05713 | 13.81 | 12.01 | 215.5 | 90.47 | 0.5395 | | 110 | 0.8732 | 0.9107 | 0.02603 | 10.9 | 46.57 | 171.9 | 82.75 | 0.5198 | ============================================================================================================= Optimal Hyperparameters: {'colsample_bytree': 0.610865775300284, 'learning_rate': 0.0805284415086373, 'max_depth': 13.707039129713081, 'min_child_samples': 7.262616569392997, 'n_estimators': 215.9489533887009, 'num_leaves': 87.00033587605007, 'subsample': 0.620344288616325} Best AUC Score: 0.8755665739616039