diff --git a/pandas/core/reshape/pivot.py b/pandas/core/reshape/pivot.py index b428155e722ff..52c9a8b78a328 100644 --- a/pandas/core/reshape/pivot.py +++ b/pandas/core/reshape/pivot.py @@ -204,12 +204,6 @@ def __internal_pivot_table( table = agged.unstack(to_unstack) if not dropna: - if isinstance(table.index, MultiIndex): - m = MultiIndex.from_arrays( - cartesian_product(table.index.levels), names=table.index.names - ) - table = table.reindex(m, axis=0) - if isinstance(table.columns, MultiIndex): m = MultiIndex.from_arrays( cartesian_product(table.columns.levels), names=table.columns.names