logisticregression1 [머신러닝] Logistic Regression, Dealing NaN 리니어 리그레션과 다르게 로지스틱 리그레션은 분류를 위해 모델링된다. 예시로 물건을 구매할사람과 아닌사람을 예상해서 분류할수있다. # 0.5 를 기준으로 0과 1로 나누는 과정 나이와 연봉을 분석해서 물건을 구매할지 안할지 분류하자 df= 데이터를 기반으로 트레인 테스트 스플릿 과정까지 진행하자. df.isna().sum() #Nan 없음 X = df.loc[: ,'Age':'EstimatedSalary' ] y = df['Purchased'] from sklearn.preprocessing import StandardScaler scaler = StandardScaler() X = scaler.fit_transform(X) from sklearn.model_selection import train_te.. 2022. 5. 6. 이전 1 다음