a. Understanding data #导入数据包fromsklearnimportsvmimportpandasaspdimportnumpyasnu#将下载后的数据集进行数据训练importosos.chdir(r'E:\Titanic\titanic')#训练数据集train=pd.read_csv('./train.csv')#训练测试集test=pd.read_csv('./test.csv')#查看数据集大小print('train:',train.shape,'test:',t...
Explore and run machine learning code with Kaggle Notebooks | Using data from Titanic - Machine Learning from Disaster
7.预测生成结果,提交kaggle 机器学习(人工智能)的基础是数据分析(描述统计) 核心是特征分类 产品是判断结果(推论统计) 1.导数据/导包 #忽略警告提示importwarningswarnings.filterwarnings('ignore')#导入处理数据包importnumpyasnpimportpandasaspd#导入数据#训练数据集train=pd.read_csv("C:/train.csv")#测试数据...
machine-learningdeep-learningtitanic-kaggletitanic-survival-predictiontitanic-dataset UpdatedJul 4, 2021 Python Predicting the survival of passengers on RMS Titanic using information about the passengers. rtitanic-kaggletitanic-survival-predictiontitanic-dataset ...
Python Table of Contents Imputing missing values using Central Tendency (Mean, Median or Mode)Dealing with outliersBuilding the model using Decision Tree Classifier Competition Notebook Titanic - Machine Learning from Disaster Public Score 0.71531 Best Score 0.76794 V1 License This Notebook has been re...
A prediction of a passenger's survival in the Titanic based on various features such as age, gender, class, and more. Explore the project » Report Bug · Request Feature Welcome to the Titanic Classification project repository! This project aims to predict whether a passenger on the Tit...
Python 的sklearn库包含许多可用于机器学习的工具,本文以经典的泰坦尼克号问题为例,来说明在Python中使用sklearn做机器学习的一般流程。由于本人对机器学习了解还不深,对于本文内容如有任何建议或意见,欢迎提出!闲话少说,咱们立即进入主题。 1. 读取并查看数据 泰坦尼克号问题,Kaggle上提供了较为详细的数据说明和下载...
roc_survival = roc_curve(train_data[['Survived']], y_pred) sns.set_style("whitegrid") sns.plt.plot(roc_survival[0], roc_survival[1]) sns.plt.show() Logistic Regression using Scikit-Learn Here we shall learn how to perform modeling using sci-kit-learn: ...
The Titanic challenge hosted by Kaggle is a competition in which the goal is to predict the survival or the death of a given passenger based on a set of variables describing him such as his age, his sex, or his passenger class on the boat. I have been playing with the Titanic dataset...
Kaggle竞赛(lecture 1-1 入门)Titanic介绍 Titanic: Machine Learning from Disaster Start here! Predict survival on the Titanic and get familiar with ML basics 目录 Titanic Machine Learning from Disaster 目录1Kaggle介绍 1规则 2排行榜 3讨论 4内核 2概述 1描述 2评估...