0
$\begingroup$

For multiple linear regression problem, I have both categorical and numerical variables in the data. I am checking the correlation for numerical variables for EDA and standardizing them by taking log. For rest of the categorical variable columns contains 2 values (either 0 or 1). So I wanted to understand if we should consider categorical variables in the correlation matrix alongside numerical vars and keep them as is with log-transformed numerical variables in input for the regression model. Please guide.

$\endgroup$

1 Answer 1

0
$\begingroup$

https://stats.stackexchange.com/questions/484299/how-to-check-the-correlation-between-categorical-and-numeric-independent-variabl/484300#484300 This link mentions a couple of approaches (albiet in R, need to look for corresponding implementations in Python). These approaches assume the categorical variable to be dichotomous, which is true in your case

1.https://en.wikipedia.org/wiki/Point-biserial_correlation_coefficient Point biserial correlation

For Python- please check this https://www.statology.org/point-biserial-correlation-python/

2.http://www.sthda.com/english/wiki/unpaired-two-samples-wilcoxon-test-in-r

Please let me know, it this was helpful

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.