To calculate spearman or kendall correlation.
import pandas as pd
import fairlens as fl
col_names = ["gender", "nationality", "random", "corr1", "corr2"]
data = [
["woman", "spanish", 715, "w", 20],
["man", "spanish", 1008, "m", 20],
["man", "french", 932, "m", 10],
["woman", "french", 1300, "w", 10],
]
df = pd.DataFrame(data, columns=col_names)
fl.sensitive.find_sensitive_correlations(df)
Is there an existing issue for this?
Describe the bug
When trying to use the function
sensitive.find_sensitive_correlationswhere one of the columns being tested is a string, it would still still try to calculate pearson correlation and returns an error.Expected Behavior
To calculate spearman or kendall correlation.
Steps To Reproduce
Environment
Anything else? Screenshots?
No response