Giter Site home page Giter Site logo

jackxu2020 / cmb-credit-card-risk-prediction Goto Github PK

View Code? Open in Web Editor NEW

This project forked from yangj96/cmb-credit-card-risk-prediction

0.0 0.0 0.0 112 KB

招商银行2020FinTech精英训练营数据赛道-信用风险评分预测

Jupyter Notebook 100.00%

cmb-credit-card-risk-prediction's Introduction

招商银行2020FinTech精英训练营数据赛道-信用风险评分预测

基于用户标签数据、过去60天的交易行为数据、过去30天的APP行为数据,构建信用违约预测模型,预测评分数据集中每个用户的违约概率,线上AUC 0.77138

数据预处理

对缺失值根据数据分布进行填充(某些字段存在缺失值的同时有“\N”、“~”等值,主要是避免修改这类字段的分布) atdd_type中的0和0.0统一为0,1和1.0统一为1 分层类别字段labelencoder编码 时间字段提取出距今秒数,天数,年月日、小时、星期、是否周末等字段 年龄分桶

特征工程
针对用户交易表

构造用户历史交易收入支出次数统计以及细化类别的计数类特征、收入支出总金额统计、用户当前余额信息以及用户收支分类一级编码的类别统计量; 细化交易金额统计量,包括:交易最大金额、最小金额、交易金额均值、方差; 细化最近一次交易和交易频率特征,包括:最后一次交易时间、最后一次交易时间是否晚于平均值、多少天有交易行为、平均每天交易次数、平均每天交易金额; 细化比例类特征,包括:双向交易行为的金额比例(贷存比)

针对用户行为表

构造用户访问页面编码的各类别次数统计,使用各类别的target encoding分数作为权重相乘以及用户行为总次数,总天数,平均每天次数等计数统计量; 构造用户行为序列,使用tf-dif特征或使用nlp模型处理用户行为序列。Tf-idf将用户行为序列中的page_no集合看作一篇文档,将每个page_no视为文档中的文字使用tfidf(需要利用sklearn中的TfidfVectorizer的max_df和min_df进行参数调整降低维度)。NLP模型则将每个用户点击的page_no列表构造作为句子,使用word2vec来构造page_no嵌入表示,然后使用简单的统计操作得到用户的向量表示,例如将用户近期行为中page_no的embedding向量进行加权平均,或者利用attention以及RNN/LSTM/GRU/Transformer等方法进行序列建模。

模型验证融合

采用5折交叉验证,将cat、xgb、lgb多类树模型stacking融合

cmb-credit-card-risk-prediction's People

Contributors

yangj96 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.