日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

ML之RF:利用Pipeline(客户年龄/职业/婚姻/教育/违约/余额/住房等)预测客户是否购买该银行的产品二分类(预测、推理)

發(fā)布時(shí)間:2025/3/21 编程问答 31 豆豆
生活随笔 收集整理的這篇文章主要介紹了 ML之RF:利用Pipeline(客户年龄/职业/婚姻/教育/违约/余额/住房等)预测客户是否购买该银行的产品二分类(预测、推理) 小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

ML之RF:利用Pipeline(客戶年齡/職業(yè)/婚姻/教育/違約/余額/住房等)預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品二分類(預(yù)測(cè)、推理)

?

?

?

?

目錄

利用Pipeline(客戶年齡/職業(yè)/婚姻/教育/違約/余額/住房等)預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品二分類(預(yù)測(cè)、推理)

數(shù)據(jù)說明

輸出結(jié)果

查看數(shù)據(jù)分布

?分析數(shù)據(jù)

輸出訓(xùn)練過程

導(dǎo)出推理結(jié)果


?

?

?

相關(guān)文章
ML之RF:利用Pipeline(客戶年齡/職業(yè)/婚姻/教育/違約/余額/住房等)預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品二分類(預(yù)測(cè)、推理)
ML之RF:利用Pipeline(客戶年齡/職業(yè)/婚姻/教育/違約/余額/住房等)預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品二分類(預(yù)測(cè)、推理)全部代碼

利用Pipeline(客戶年齡/職業(yè)/婚姻/教育/違約/余額/住房等)預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品二分類(預(yù)測(cè)、推理)

數(shù)據(jù)說明

? ? ? ? 該數(shù)據(jù)集是葡萄牙銀行機(jī)構(gòu)進(jìn)行營銷活動(dòng)所得。這些營銷活動(dòng)一般以電話為基礎(chǔ),銀行的客服人員至少聯(lián)系客戶一次,以確認(rèn)客戶是否有意愿購買該銀行的產(chǎn)品(定期存款)。目標(biāo)是預(yù)測(cè)客戶是否購買該銀行的產(chǎn)品。

NO字段名稱數(shù)據(jù)類型字段描述
1IDInt客戶唯一標(biāo)識(shí)
2ageInt客戶年齡
3jobString客戶的職業(yè)
4maritalString婚姻狀況
5educationString受教育水平
6defaultString是否有違約記錄
7balanceInt每年賬戶的平均余額
8housingString是否有住房貸款
9loanString是否有個(gè)人貸款
10contactString與客戶聯(lián)系的溝通方式
11dayInt最后一次聯(lián)系的時(shí)間(幾號(hào))
12monthString最后一次聯(lián)系的時(shí)間(月份)
13durationInt最后一次聯(lián)系的交流時(shí)長
14campaignInt在本次活動(dòng)中,與該客戶交流過的次數(shù)
15pdaysInt距離上次活動(dòng)最后一次聯(lián)系該客戶,過去了多久(999表示沒有聯(lián)系過)
16previousInt在本次活動(dòng)之前,與該客戶交流過的次數(shù)
17poutcomeString上一次活動(dòng)的結(jié)果
18yInt預(yù)測(cè)客戶是否會(huì)訂購定期存款業(yè)務(wù)

數(shù)據(jù)參考:Citation:?[Moro et al., 2014] S. Moro, P. Cortez and P. Rita. A Data-Driven Approach to Predict the Success of Bank Telemarketing. Decision Support Systems, Elsevier, 62:22-31, June 2014

?

輸出結(jié)果

查看數(shù)據(jù)分布


分析數(shù)據(jù)

?# ? Column ? ? Non-Null Count ?Dtype? --- ?------ ? ? -------------- ?-----?0 ? ID ? ? ? ? 25317 non-null ?int64?1 ? age ? ? ? ?25317 non-null ?int64?2 ? job ? ? ? ?25317 non-null ?object3 ? marital ? ?25317 non-null ?object4 ? education ?25317 non-null ?object5 ? default ? ?25317 non-null ?object6 ? balance ? ?25317 non-null ?int64?7 ? housing ? ?25317 non-null ?object8 ? loan ? ? ? 25317 non-null ?object9 ? contact ? ?25317 non-null ?object10 ?day ? ? ? ?25317 non-null ?int64?11 ?month ? ? ?25317 non-null ?object12 ?duration ? 25317 non-null ?int64?13 ?campaign ? 25317 non-null ?int64?14 ?pdays ? ? ?25317 non-null ?int64?15 ?previous ? 25317 non-null ?int64?16 ?poutcome ? 25317 non-null ?object17 ?y ? ? ? ? ?25317 non-null ?int64? dtypes: int64(9), object(9) memory usage: 3.5+ MB訓(xùn)練集計(jì)算相關(guān)系數(shù):?y ? ? ? ? ? 1.000000 ID ? ? ? ? ?0.556627 duration ? ?0.394746 pdays ? ? ? 0.107565 previous ? ?0.088337 campaign ? ?0.075173 balance ? ? 0.057564 day ? ? ? ? 0.031886 age ? ? ? ? 0.029916訓(xùn)練集 y標(biāo)簽的比例: 0.11695698542481336 依次查看訓(xùn)練集、測(cè)試集中,類別型字段的細(xì)分類 job ['admin.', 'blue-collar', 'entrepreneur', 'housemaid', 'management', 'retired', 'self-employed', 'services', 'student', 'technician', 'unemployed', 'unknown'] job ['admin.', 'blue-collar', 'entrepreneur', 'housemaid', 'management', 'retired', 'self-employed', 'services', 'student', 'technician', 'unemployed', 'unknown'] marital ['divorced', 'married', 'single'] marital ['divorced', 'married', 'single'] education ['primary', 'secondary', 'tertiary', 'unknown'] education ['primary', 'secondary', 'tertiary', 'unknown'] default ['no', 'yes'] default ['no', 'yes'] housing ['no', 'yes'] housing ['no', 'yes'] loan ['no', 'yes'] loan ['no', 'yes'] contact ['cellular', 'telephone', 'unknown'] contact ['cellular', 'telephone', 'unknown'] month ['apr', 'aug', 'dec', 'feb', 'jan', 'jul', 'jun', 'mar', 'may', 'nov', 'oct', 'sep'] month ['apr', 'aug', 'dec', 'feb', 'jan', 'jul', 'jun', 'mar', 'may', 'nov', 'oct', 'sep'] poutcome ['failure', 'other', 'success', 'unknown'] poutcome ['failure', 'other', 'success', 'unknown']

輸出訓(xùn)練過程

Fitting 7 folds for each of 32 candidates, totalling 224 fits [Parallel(n_jobs=-1)]: Using backend LokyBackend with 4 concurrent workers. [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 31.1s [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 31.0s [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 31.7s [CV] forst_reg__max_features=45, forst_reg__n_estimators=50 .......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 32.2s [CV] forst_reg__max_features=45, forst_reg__n_estimators=100 ......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 27.1s [CV] forst_reg__max_features=45, forst_reg__n_estimators=100 ......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 27.1s [CV] forst_reg__max_features=45, forst_reg__n_estimators=50, total= 26.6s [CV] forst_reg__max_features=45, forst_reg__n_estimators=100 ......... [CV] forst_reg__max_features=45, forst_reg__n_estimators=100 .........

導(dǎo)出推理結(jié)果

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

總結(jié)

以上是生活随笔為你收集整理的ML之RF:利用Pipeline(客户年龄/职业/婚姻/教育/违约/余额/住房等)预测客户是否购买该银行的产品二分类(预测、推理)的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。