How to correlate an Ordinal Categorical column in pandas?

后端 未结 3 1619
长情又很酷
长情又很酷 2021-01-31 19:13

I have a DataFrame df with a non-numerical column CatColumn.

   A         B         CatColumn
0  381.1396  7.343921  Medium
1  481.3268         


        
3条回答
  •  南方客
    南方客 (楼主)
    2021-01-31 19:47

    Basically, there is no a good scientifical way to do it. I would use the following approach: 1. Split the numeric field into n groups, where n = number of groups of the categorical field. 2. Calculate Cramer correlation between the 2 categorical fields.

提交回复
热议问题