로딩
요청 처리 중입니다...

Python : 위스콘신 유방암 데이터 분류분석(1)

 Python : 위스콘신 유방암 데이터 분류분석(1)

xgboost를 이용한 분류 1) Import packages import pandas as pd import numpy as np from sklearn.model_selection import train_test_split import matplotlib.pyplot as plt import xgboost as xgb from xgboost import plot_importance from xgboost import plot_importance 2) 데이터 전처리 df= pd.read_csv('wisc_bc_data.csv') df.head() df = df.drop('id', axis=1) df.head() df['diagnosis'] = df['diagnosis'].apply(lambda x : 1 if x== "M" else 0) x_train, x_test, y_train, y_test = train_test_split(df.iloc[:,1:], df['diagnosis'...

# python # xgboost