[2022 동계 인턴십]암예측 4
이전에서 포스팅한 내용에서 중요도(feature_importance)를 0.5까지 잘라서 시행했다. #폐암 features=['LUNG','STOMA','COLON','LIVER','LUNG','PROST','THROI','BREAC','RECTM'] y_df =df['LUNG'] #X_df =df.drop(features, axis=1) X_df =df[['AGE_B','GOT_B','SBP_B','LDL_B','HDL_B','DBP_B','CHO_B','WT_B','FBS_B','GPT_B']] X_train, X_test, y_train, y_test = train_test_split(X_df, y_df, test_size=0.2, random_state=156) print(X_train.shape..
2022. 2. 16.
[동계인턴십] 암 예측 2
features=['STOMA','COLON','LIVER','LUNG','PROST','THROI','BREAC','RECTM'] y_df =df['LUNG'] X_df =df.drop(features, axis=1) from sklearn.model_selection import train_test_split X_train,X_test,y_train,y_test = train_test_split(X_df,y_df,test_size=0.2) from sklearn.tree import DecisionTreeClassifier from sklearn.ensemble import RandomForestClassifier from sklearn.linear_model import LogisticRegress..
2022. 1. 11.