시작하기무료로 시작하기

로지스틱 회귀 예측

선형 회귀와 마찬가지로, 로지스틱 회귀의 장점은 예측을 할 수 있다는 점이에요. 예측 흐름을 한 번 더 차근차근 따라가 보겠습니다!

churnmdl_churn_vs_both_inter가 준비되어 있고, itertools.product가 로드되어 있습니다.

이 연습은 강의의 일부입니다

Python의 statsmodels로 배우는 중급 회귀

강의 보기

실습형 인터랙티브 연습

이 예제를 이 샘플 코드를 완성하여 풀어보세요.

# Create time_since_first_purchase
time_since_first_purchase = ____

# Create time_since_last_purchase
time_since_last_purchase = ____

# Create p as all combinations of values of time_since_first_purchase and time_since_last_purchase
p = ____

# Transform p to a DataFrame and name the columns
explanatory_data = ____

# Print the result
print(explanatory_data)
코드 편집 및 실행