【发布时间】:2017-09-09 16:57:00
【问题描述】:
我一直在尝试在 python 中向这个数据集添加一个新的 id 列
0000008::Edison Kinetoscopic Record of a Sneeze (1894)::Documentary|Short
0000010::La sortie des usines Lumière (1895)::Documentary|Short
0000012::The Arrival of a Train (1896)::Documentary|Short
25::The Oxford and Cambridge University Boat Race (1895)::
0000091::Le manoir du diable (1896)::Short|Horror
0000417::Le voyage dans la lune (1902)::Short|Adventure|Fantasy
0000439::The Great Train Robbery (1903)::Short|Action|Crime
0443::Hiawatha, the Messiah of the Ojibway (1903)::
0000628::The Adventures of Dollie (1908)::Action|Short
我要做的是在开头添加一个带有 id 的列,所以它看起来像这样,但我不确定我会怎么做。如果有人可以帮助我解决它,我会很高兴。
0::0000008::Edison Kinetoscopic Record of a Sneeze (1894)::Documentary|Short
1::0000010::La sortie des usines Lumière (1895)::Documentary|Short
2::0000012::The Arrival of a Train (1896)::Documentary|Short
3::25::The Oxford and Cambridge University Boat Race (1895)::
4::0000091::Le manoir du diable (1896)::Short|Horror
5::0000417::Le voyage dans la lune (1902)::Short|Adventure|Fantasy
6::0000439::The Great Train Robbery (1903)::Short|Action|Crime
7::0443::Hiawatha, the Messiah of the Ojibway (1903)::
8::0000628::The Adventures of Dollie (1908)::Action|Short
【问题讨论】: