I think I discovered a small bug when running cell 17. The MultiIndex constructor takes "codes" not "labels" as its input when doing the internal encoding. Tested on pandas 2.2.2.
The original error was: TypeError: new() got an unexpected keyword argument 'labels'
I think I discovered a small bug when running cell 17. The MultiIndex constructor takes "codes" not "labels" as its input when doing the internal encoding. Tested on pandas 2.2.2.
The original error was: TypeError: new() got an unexpected keyword argument 'labels'