Open
Description
In #47215 I brought up the issue of allowing sets as arguments for the DataFrame
constructor. This was addressed in #47231 . But there are a few more cases that should be fixed:
>>> pd.Series([3,4,5], index=set(["a", "b", "c"]))
c 3
a 4
b 5
dtype: int64
>>> pd.DataFrame.from_records([[1,2,3]], columns=set(["a", "b", "c"]), index=set(["x", "y", "z"]))
c a b
x 1 2 3
y 1 2 3
z 1 2 3
We shouldn't allow a set
as an argument for index
or columns
in both these cases.