안녕하세요 늑대양입니다 🥳 오늘은 가짜연구소 스터디 18주차 학습 내용을 안내해드리도록 하겠습니다. 프로그램: Data Scientist - Python - 황지*님/이다*님 18주차 학습 주제: Supervised Learning with scikit-learn 18주차 학습 material URL: https://www.datacamp.com/courses/supervised-learning-with-scikit-learn Index Classification Regression Fine-Tuning Your Model Preprocessing and Pieplines 긴 글 읽어주셔서 감사합니다 🤗
# page 79 ~ 86 두 번째 머신러닝 프로그램: 이전에 만든 훈련 세트와 테스트 세트로 k-최근접 이웃 모델을 훈련시켜 봅시다. fit() 메서드를 실행할 때마다 KNeighborsClassifier 클래스의 객체는 이전에 학습한 모든 것을 잃어버립니다. 이전 모델을 그대로 두고 싶다면 KNeighborsClassifier 클래스 객체를 새로 만들어야 합니다. kn = kn.fit(train_input, train_target) kn.score(test_input, test_target) # 출력 결과물 1.0 100%의 정혹도로 테스트 세트에 있는 생성 확인 가능! predict() 메서드로 테스트 세트의 예측 결과와 실제 타깃 비교: kn.predict(test_input) # 출력 결과물 a..