Logistic regression prediction
जैसा कि linear regression में होता है, logistic regression की खासियत यह है कि आप prediction कर सकते हैं। आइए prediction के flow को एक बार फिर चरणबद्ध तरीके से समझें!
churn और mdl_churn_vs_both_inter उपलब्ध हैं; itertools.product लोड किया हुआ है.
यह अभ्यास पाठ्यक्रम का हिस्सा है
इंटरमीडिएट Regression with statsmodels in Python
इंटरैक्टिव व्यावहारिक अभ्यास
इस अभ्यास को इस नमूना कोड को पूरा करके आज़माएँ।
# 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)