You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hie,
in your tuto you write "The index of a DataFrame is a set (i.e. each element is only represented once) that consists of a label for each row".
IMHO this is not true.
2 rows may have the same label
example :
data = [{'A': 'x', 'B': 'y', 'C':'z'}, {'A':'x', 'B': 'u', 'C': 'v'}]
df = pandas.DataFrame(data)
df.set_index(["A"])
The text was updated successfully, but these errors were encountered:
You're right - as it stands now, more accurate phrasing would be that the index of a DataFrame should be a set. While duplicating a value in the index is possible, it's both very slow and not well supported by the suite of index-based pandas functionality (read: expect errors).
Hie,
in your tuto you write "The index of a DataFrame is a set (i.e. each element is only represented once) that consists of a label for each row".
IMHO this is not true.
2 rows may have the same label
example :
data = [{'A': 'x', 'B': 'y', 'C':'z'}, {'A':'x', 'B': 'u', 'C': 'v'}]
df = pandas.DataFrame(data)
df.set_index(["A"])
The text was updated successfully, but these errors were encountered: