शुरू करेंमुफ़्त में शुरू करें

Different levels of interaction

जब आपके पास तीन explanatory variables होते हैं, तो interactions निर्दिष्ट करने के विकल्प बढ़ जाते हैं। आप बिना किसी interaction के मॉडल बना सकते हैं। आप 2-way interactions जोड़ सकते हैं, जिससे वैरिएबल्स की हर जोड़ी के लिए मॉडल coefficients मिलते हैं। तीसरा विकल्प है कि आप सभी interactions शामिल करें, यानी तीनों 2-way interactions के साथ-साथ सभी तीन explanatory variables के बीच का 3-way interaction भी।

जैसे-जैसे explanatory variables की संख्या बढ़ती है, interaction की संभावनाएँ बहुत तेज़ी से बढ़ती हैं।

taiwan_real_estate उपलब्ध है।

यह अभ्यास पाठ्यक्रम का हिस्सा है

इंटरमीडिएट Regression with statsmodels in Python

पाठ्यक्रम देखें

इंटरैक्टिव व्यावहारिक अभ्यास

इस अभ्यास को इस नमूना कोड को पूरा करके आज़माएँ।

# Model price vs. no. of conv. stores, sqrt dist. to MRT station & house age, no global intercept, no interactions
mdl_price_vs_all_no_inter = ____

# See the result
print(mdl_price_vs_all_no_inter.params)
कोड संपादित करें और चलाएँ