Say I have a categorical feature, color, which takes the values
[\'red\', \'blue\', \'green\', \'orange\'],
and I want to use it to predict something in a ra
You have to make the categorical variable into a series of dummy variables. Yes I know its annoying and seems unnecessary but that is how sklearn works. if you are using pandas. use pd.get_dummies, it works really well.