Xinrong Meng created SPARK-53050:
------------------------------------
Summary: MultiIndex.to_series() should return tuples for each entry
Key: SPARK-53050
URL: https://issues.apache.org/jira/browse/SPARK-53050
Project: Spark
Issue Type: Sub-task
Components: PS
Affects Versions: 4.1.0
Reporter: Xinrong Meng
MultiIndex.to_series() in pandas-on-Spark returns lists for each entry, whereas
pandas returns tuples.
{code:python}
>>> arrays = [[1, 2], ["red", "blue"]]
>>> pidx = pd.MultiIndex.from_arrays(arrays, names=("number", "color"))
>>> psidx = ps.from_pandas(pidx)
>>> pidx.to_series()
number color
1 red (1, red)
2 blue (2, blue)
dtype: object
>>> psidx.to_series()
number color
1 red [1, red]
2 blue [2, blue]
dtype: object
{code}
that applies for both ANSI on and off
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]