【DWJ_1703225514】基于Sklearn航空公司服务质量分析

【Talk is cheap】

复制代码
# 导入库
import warnings
warnings.filterwarnings('ignore')

import pandas as pd 

import seaborn as sns
import matplotlib.pyplot as plt
plt.rcParams['font.sans-serif'] = ['SimHei']
plt.rcParams['axes.unicode_minus'] = False 
%matplotlib inline

from sklearn.model_selection import train_test_split
from sklearn.ensemble import RandomForestClassifier
from sklearn.metrics import classification_report

1 加载数据

数据集中缺失数据占的百分比为:
Unnamed: 0 0.000000
id 0.000000
Gender 0.000000
Customer Type 0.000000
Age 0.000000
Type of Travel 0.000000
Class 0.000000
Flight Distance 0.000000
Inflight wifi service 0.000000
Departure/Arrival time convenient 0.000000
Ease of Online booking 0.000000
Gate location 0.000000
Food and drink 0.000000
Online boarding 0.000000
Seat comfort 0.000000
Inflight entertainment 0.000000
On-board service 0.000000
Leg room service 0.000000
Baggage handling 0.000000
Checkin service 0.000000
Inflight service 0.000000
Cleanliness 0.000000
Departure Delay in Minutes 0.000000
Arrival Delay in Minutes 0.298352
satisfaction 0.000000

2 探索性分析

3 机器学习

3.1 分割数据

3.2 标签编码

3-3 随机森林

3-4 分类报告

相关推荐
AI_gurubar2 小时前
大模型教机器人叠衣服:2025年”语言理解+多模态融合“的智能新篇
人工智能·机器人
飞翔的佩奇2 小时前
【完整源码+数据集+部署教程】表盘指针检测系统源码和数据集:改进yolo11-CA-HSFPN
python·yolo·计算机视觉·数据集·yolo11·表盘指针检测
larance2 小时前
SQLAlchemy 的异步操作来批量保存对象列表
数据库·python
搏博3 小时前
基于Python3.10.6与jieba库的中文分词模型接口在Windows Server 2022上的实现与部署教程
windows·python·自然语言处理·flask·中文分词
XINVRY-FPGA3 小时前
EPM240T100I5N Altera FPGA MAX II CPLD
人工智能·嵌入式硬件·fpga开发·硬件工程·dsp开发·射频工程·fpga
lxmyzzs4 小时前
pyqt5无法显示opencv绘制文本和掩码信息
python·qt·opencv
HuggingFace4 小时前
开源开发者须知:欧盟《人工智能法案》对通用人工智能模型的最新要求
人工智能
萧鼎5 小时前
Python pyzmq 库详解:从入门到高性能分布式通信
开发语言·分布式·python
媒体人8885 小时前
GEO 优化专家孟庆涛:技术破壁者重构 AI 时代搜索逻辑
大数据·人工智能
小菜AI科技5 小时前
Windsurf 评测:这款 人工智能 IDE 是你需要的颠覆性工具吗?
人工智能