How to play with .cat.codes and get_dummies I may be lost here and this might be a stupid question.
I know that get_dummies returns multiple columns depending upon the number of variables and .cat.code returns a single column with unique integers per unique value(Please correct me if I'm wrong).
I know fro .cat.codes is for categorical data and get_dummies is for object.

Can I use astype(&quot;Category&quot;) on an object and use .cat.codes on it?
Anything more that you know of to make analysis(and visualization) easier when it comes to these funtions?
You can convert object dtype to category using astype(&quot;Category&quot;) and then do label encoding on it using .cat.codes but it's better to use sklearn.preprocessing.LabelEncoder for it.
For basic analysis you should look into seaborn