Hey guys,I am still a beginner when it comes to data analysis, especially in Python. I exercise linear regression. The DV is continuous, the IV are:1. gender (either 0 or 1)2. DISTRESS (scale from 1-5)3. FEAR (scale from 1-5)4. Interaction between FEAR and genderI want to use some statistics and therefore used the following command:test = OLSInfluence(results).summary_frame()If I do this without the interaction term, then there is no problem but when the interaction term is in there, I get the following warnings:There are diverse warnings. I wonder: What can and should I do now? Can I use the values that will be put out despite the warning?
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/statsmodels/stats/outliers_influence.py:309: RuntimeWarning: invalid value encountered in sqrt
return self.results.resid / sigma / np.sqrt(1 - hii)
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/scipy/stats/_distn_infrastructure.py:879: RuntimeWarning: invalid value encountered in greater
return (self.a < x) & (x < self.b)
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/scipy/stats/_distn_infrastructure.py:879: RuntimeWarning: invalid value encountered in less
return (self.a < x) & (x < self.b)
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/scipy/stats/_distn_infrastructure.py:1818: RuntimeWarning: invalid value encountered in less_equal
cond2 = cond0 & (x <= self.a)
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/statsmodels/stats/outliers_influence.py:323: RuntimeWarning: invalid value encountered in sqrt
dffits_ = self.resid_studentized_internal * np.sqrt(hii / (1 - hii))
/Users/henrikeckermann/anaconda3/lib/python3.6/site-packages/statsmodels/stats/outliers_influence.py:352: RuntimeWarning: invalid value encountered in sqrt
dffits_ = self.resid_studentized_external * np.sqrt(hii / (1 - hii))
Thanks for any help!Henrik
Joseph,thank you very much. I deleted the topic just when you wanted to answer.I made the following mistake:I wrote: ‚ANXIETY ~ DISTRESS + GENDER+ FEAR + INTERACTION‘When I did not calculate the interaction myself before but just do:‚ANXIETY ~ DISTRESS + GENDER*FEAR‘everything worked fine.