Return the integer codes behind the categorical version of orders["city"]
pandas · from Categories and memory
category dtypeCategoricalDtypeordered.cat accessormemory_usageobserved=Putting the kettle on…
Starting up…
Exercise 2
Return the integer codes behind the categorical version of orders["city"].
your answer
stuck? the lesson behind it
Categories and memory
Store each value once — and get meaningful sorting for free.